gnu-binutils-strings utf-8而不是utf-16或ascii [英] gnu-binutils-strings utf-8 instead of utf-16 or ascii

查看:108
本文介绍了gnu-binutils-strings utf-8而不是utf-16或ascii的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我注意到gnu-binutils-strings可以在文件中打印utf-16内容-程序是否可以打印出utf-8字符串?如果是这样,哪个参数合适?我正在使用子进程的python环境中工作,并且希望使用子进程gnu-binutils-strings的输出.Popen调用将通过管道生成.

I've noticed gnu-binutils-strings can printout utf-16 content in a file - is it possible for the program to print out utf-8 strings? if so, which arguments are appropriate? i'm working in a python environment using subprocess and would like to work with the output from gnu-binutils-strings that a subprocess.Popen call would generate through a pipe.

推荐答案

我对strings并不熟悉,但是我使用的版本(2.21.51.20110605)具有8位编码选项(-eS),使用utf-8文字.必须寻找一个由不可打印字符(值<32)定界的文本"的宽广的网.我希望有很多噪音.对随机可执行文件进行的测试显示-eS(8位)结果比-es(7位)大5倍.

I'm not experienced with strings, but the version I have (2.21.51.20110605) has an 8-bit encoding option (-eS) that would work with utf-8 text. It must have to cast a wide net looking for 'text' delimited by non-printable characters (value < 32). I'd expect a lot of noise. A test on a random executable showed the -eS (8-bit) result was 5 times bigger than -es (7-bit).

这篇关于gnu-binutils-strings utf-8而不是utf-16或ascii的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆