Comments (6)
It must be it.
Python 3
xortool -o -x key.txt
Traceback (most recent call last):
File "/usr/bin/xortool", line 381, in <module>
main()
File "/usr/bin/xortool", line 53, in main
ciphertext = get_ciphertext()
File "/usr/bin/xortool", line 96, in get_ciphertext
ciphertext = decode_from_hex(ciphertext)
File "/usr/lib/python3.7/site-packages/xortool/routine.py", line 58, in decode_from_hex
only_hex_digits = "".join([c for c in text if c in string.hexdigits])
File "/usr/lib/python3.7/site-packages/xortool/routine.py", line 58, in <listcomp>
only_hex_digits = "".join([c for c in text if c in string.hexdigits])
TypeError: 'in <string>' requires string as left operand, not int
Python 2
xortool -o -x key.txt
The most probable key lengths:
2: 38.3%
5: 22.7%
10: 26.9%
17: 6.4%
20: 5.6%
Key-length can be 5*n
100 possible key(s) of length 2:
\n\x15
\x0b\x14
\x08\x17
\t\x16
\x0e\x11
...
Found 50 plaintexts with 95.0%+ printable characters
See files filename-key.csv, filename-char_used-perc_printable.csv
from xortool.
Also: with python3.7.2:
$ xortool-xor -h 607b7b7b -h 3f3c3e2f
Traceback (most recent call last):
File "/usr/bin/xortool-xor", line 117, in <module>
main()
File "/usr/bin/xortool-xor", line 40, in main
v = arg_data(c, val)
File "/usr/bin/xortool-xor", line 110, in arg_data
return from_hex(s)
File "/usr/bin/xortool-xor", line 95, in from_hex
return res.decode("hex")
AttributeError: 'str' object has no attribute 'decode'
from xortool.
$ python2 /usr/bin/xortool-xor -h 607b7b7b -h 3f3c3e2f
_GET
As @redfast00 spotted, this is totally a matter of shebang.
from xortool.
possible solution for hex encoding:
def decode_from_hex(text):
only_hex_digits = "".join([chr(c) for c in text if chr(c) in string.hexdigits])
return bytes.fromhex(only_hex_digits)
from xortool.
Also #26 fixes this issue.
from xortool.
I think should work now on master (not on PyPI yet)
from xortool.
Related Issues (20)
- ImportError: No module named docopt HOT 5
- Installation issue on Windows HOT 1
- new line character at the end of xor file HOT 1
- Getting a Type Error HOT 4
- not working on Python 3.7 HOT 3
- xortool-xor is not python 3 compatible HOT 4
- xortool-xor new line HOT 1
- Ubuntu under windows HOT 1
- error under kali HOT 1
- Issue importing COLORS line 55 xortool file HOT 2
- xortool : command not found HOT 3
- Can't execute this package
- Dependency on 'importlib_metadata' missing HOT 2
- Cracked fail (may with long file?) HOT 1
- Can your tool analyse binary files that are xor-scrambled? HOT 1
- error after running bruteforce HOT 1
- How to properly decrypt xored text with xortool? HOT 1
- Incorrect comparison HOT 1
- Why can't find solution?
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from xortool.