[UPDATE] add crypt version
This commit is contained in:
+3
-1
@@ -6,12 +6,14 @@ cd $(dirname $0)/conf-client/
|
||||
SondeFile=$(pwd)/sonde.cfg
|
||||
source service.cfg
|
||||
|
||||
[[ "${Crypted}" == "yes" ]] && NcCmd="timeout 0.1 cryptcat -k ${LocalPassword} ${RemoteIp} ${RemotePort} ${Udp}" || NcCmd="timeout 0.1 nc ${RemoteIp} ${RemotePort}"
|
||||
|
||||
|
||||
while read DATA
|
||||
do
|
||||
Cmd=$(echo $DATA| cut -d"#" -f1)
|
||||
Arg=$(echo $DATA| cut -d"#" -f2)
|
||||
Res=$(echo -e "${Cmd}#${Arg}" | timeout 0.1 cryptcat -k ${LocalPassword} ${RemoteIp} ${RemotePort} 2> /dev/null)
|
||||
Res=$( echo -e "${Cmd}#${Arg}" | eval ${NcCmd} 2> /dev/null)
|
||||
if [[ -z $Res ]]
|
||||
then
|
||||
echo "5|No sonde $Cmd on serveur $RemoteIp"
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
RemoteIp=127.0.0.1
|
||||
RemotePort=8080
|
||||
LocalPassword='Evil@MonitoR-666'
|
||||
Crypted=no
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user