你这句话“怎样用 linux strings 逆向前”看起来没说完,我猜你的意思是:
“怎样用 Linux 的 strings 命令,从文件末尾往前(逆向)提取字符串?”
下面按几种常见理解来解释。
strings 本身没有“倒序”选项strings 不能直接反向输出字符串,它是按文件顺序扫描的。
但可以用其他命令配合,实现“从后往前看字符串”。
strings,再 tac 反序strings file.bin | tac
strings:提取可打印字符串tac:按行倒序(和 cat 相反)✅ 适合:你想看最后出现的字符串在最前面
tail -c 1M file.bin | strings
进阶:
tail -c 1M file.bin | strings | tac
如果你是想从文件尾往头扫字节,可以:
rev file.bin | strings
⚠️ 注意:
rev 是按字节反转strings -n 6 binary | tac
或:
objdump -s binary | tac
常见用途:
例如:
strings -a malware.bin | grep -i "http"
如果你能补全一句话,比如:
我可以给你更精确的答案。