How to decode DES encrypted string
I've been using x11vnc for quite a while, but without any password authentication. I'm trying to add this security now. The man page says,
Quote:
Code:
# /usr/local/bin/x11vnc -auth guess -passwdfile custom:/user/util/bin/vncchxpw -repeat -modtweak I ran x11vnc as shown above and got a screen on the client asking for a password. I just entered "any". A hex dump of the /tmp/vncchxpw.log file shows: Code:
0: 0A 6E 65 78 74 0A 31 36 0A 23 36 F4 E1 03 EE 30 .next.16.#6....0 Code:
23 36 F4 E1 03 EE 30 16 85 FC E9 4C F1 F5 16 5C Code:
2C D5 5C 93 C2 21 29 3A DF C2 A2 7C E9 1F 1A D7 |
DES or 3DES? Either way, openssl is probably going to work:
Code:
openssl des3 -d -in input.txt -out output.txt |
So, if the 16 byte "challenge" string is A and the response string is B, I suppose I need something like:
Code:
echo "B" | openssl DES3 -d |
I would try feeding it to openssl using one of the many options provided by -passin.
|
Not having much luck. I've tried:
Code:
challenge='#6ôá^Cî0^VüéLñõ^V\' |
Hmm. The manual page is wrong there. :(
Code:
echo "$response" | openssl des -in - -pass "env:challenge" -d be decrypted. |
Yes, I'll try different DES ciphers when I get past the needed command syntax and if plain 'ole DES doesn't work. Meanwhile, I tried your new suggested syntax and got:
Code:
# echo "$response" | openssl des -in - -pass "env:challenge" -d Interesting that the man page is wrong. One would think openssl is a active enough program that this would be updated. My openssl version is 1.0.2K. |
All times are GMT -5. The time now is 06:14 AM. |