diff options
author | epochqwert <epoch@53flpnlls43fcguy.onion> | 2015-02-06 04:41:43 -0600 |
---|---|---|
committer | epochqwert <epoch@53flpnlls43fcguy.onion> | 2015-02-06 04:41:43 -0600 |
commit | af42bb47f92b772411cd4235c850caa0ac988a10 (patch) | |
tree | d554c838af5c6aeb1b66261e1347481571462824 /nocompile | |
parent | 3c2d290d17b739f14774dfcdf48581c1fb212286 (diff) | |
download | misc-af42bb47f92b772411cd4235c850caa0ac988a10.tar.gz misc-af42bb47f92b772411cd4235c850caa0ac988a10.zip |
ident.sh got a format string vuln fix.
ident_service.sh will ident a service given its remote IP and port. (only run if ident is running on that remote computer)
argc is just because I always forget what argc is for however many args.
peereid is for unix sockets' ids
peerip and sockip got the same upgrade. can now use the optional argv[1] to set the number of the file descriptor to use.
Diffstat (limited to 'nocompile')
-rwxr-xr-x | nocompile/bin/ident.sh | 2 | ||||
-rwxr-xr-x | nocompile/bin/ident_service.sh | 2 |
2 files changed, 3 insertions, 1 deletions
diff --git a/nocompile/bin/ident.sh b/nocompile/bin/ident.sh index 5a44253..a4827c4 100755 --- a/nocompile/bin/ident.sh +++ b/nocompile/bin/ident.sh @@ -1,2 +1,2 @@ #!/bin/sh -printf "$2 , $3\r\n" | nc $1 113 | tr -d '\r' +printf "%s , %s\r\n" "$2" "$3" | nc "$1" 113 | tr -d '\r' diff --git a/nocompile/bin/ident_service.sh b/nocompile/bin/ident_service.sh new file mode 100755 index 0000000..a77687a --- /dev/null +++ b/nocompile/bin/ident_service.sh @@ -0,0 +1,2 @@ +#!/bin/sh +ncat "$1" "$2" -c 'ident.sh '"$1"' '"$2"' $(/usr/local/libexec/sockip 3 | tail -n1) 1>&2' |