This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
#include <stdlib.h> | |
#include <signal.h> | |
#include <setjmp.h> | |
void catcher(int a) | |
{ | |
setresuid(geteuid(),geteuid(),geteuid()); | |
printf("WIN!\n"); | |
system("/bin/sh"); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
#include <stdlib.h> | |
#include <unistd.h> | |
#define answer 3.141593 | |
void main(int argc, char **argv) { | |
float a = (argc - 2)?: strtod(argv[1], 0); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
#include <unistd.h> | |
#include <string.h> | |
int good(int addr) { | |
printf("Address of hmm: %p\n", addr); | |
} | |
int hmm() { | |
printf("Win.\n"); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdlib.h> | |
int main() { | |
system("id"); | |
return 0; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
#include <string.h> | |
int main(int argc, char **argv) { | |
char buf[128]; | |
if(argc < 2) return 1; | |
strcpy(buf, argv[1]); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include<string.h> | |
// The devil is in the details - nnp | |
void copy_buffers(char *argv[]) | |
{ | |
char buf1[32], buf2[32], buf3[32]; | |
strncpy(buf2, argv[1], 31); | |
strncpy(buf3, argv[2], sizeof(buf3)); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Copyright (c) 2009 Upi Tamminen <[email protected]> | |
# See the COPYRIGHT file for more information | |
import os, time, anydbm, datetime | |
from kippo.core.honeypot import HoneyPotCommand | |
from twisted.internet import reactor | |
from kippo.core.config import config | |
from kippo.core.userdb import UserDB | |
from kippo.core import utils |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# author: joda | |
openssl=/usr/bin/openssl | |
certdir=$SSL_CERT_DIR | |
if [ ! -f $openssl ]; then | |
echo "ERROR: Can't find $openssl. openssl-util installed?" >&2 | |
fi | |
if [[ "$1" = "-f" ]]; then | |
overwrite=1 | |
shift # remove $1 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
hosts: | |
[local] | |
localhost | |
ext_vars.yml: | |
users: | |
user1: | |
password: password01 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
task: | |
... | |
- name: Add authorized_key file | |
authorized_key: user={{item.username}} key='{{ "\n".join(item.authkey) | string }}' | |
with_items: users | |
... |