当前位置:网站首页>Convert text to hexadecimal, and reverse

Convert text to hexadecimal, and reverse

2022-06-24 15:43:00 Look up to the sky

xxd

In the system log , For encrypted information and binary , Hexadecimal output can be used , Simple encryption . After encrypting and collecting logs , Need to put 16 Hexadecimal is turning back identifiable information .

There's a demo Sketch Map .

xxd -p Of the output file 16 Hexadecimal view

xxd -r -p according to 16 Base number , Output actual content

For example, in some cases , The background return result may be a json, It could also be a binary , If you print binary directly , on certain conditions , May crash directly . under these circumstances ,base64 Printing is an option , but 16 Base faster , And you can , For longer binary , Get only the first n Characters .

原网站

版权声明
本文为[Look up to the sky]所创,转载请带上原文链接,感谢
https://yzsam.com/2021/05/20210508124813621H.html