Windbg 在内存中搜索UTF8编码的字符串
使用windbg,可以在内存中搜索UTF8编码的字符串。例如,我试图在内存中查找以下字符串:Windbg 在内存中搜索UTF8编码的字符串,windbg,Windbg,使用windbg,可以在内存中搜索UTF8编码的字符串。例如,我试图在内存中查找以下字符串: memory contents: 3c 00 64 00 69 00 76 00 20 00 69 00 64 00 3d 00 corresponding string: "<.d.i.v. .i.d.=." 内存内容:3c 00 64 00 69 00 76 00 20 00 69 00 64 00 3d 00 对应的字符串:“ 或用于实际搜索字符串 lkd> s -
memory contents: 3c 00 64 00 69 00 76 00 20 00 69 00 64 00 3d 00
corresponding string: "<.d.i.v. .i.d.=."
内存内容:3c 00 64 00 69 00 76 00 20 00 69 00 64 00 3d 00
对应的字符串:“
或用于实际搜索字符串
lkd> s -u 0 L?10000000 "<div id"
009f582e 003c 0064 0069 0076 0020 0069 0064 0022 <.d.i.v. .i.d.".
009f5924 003c 0064 0069 0076 0020 0069 0064 0022 <.d.i.v. .i.d.".
00a08200 003c 0064 0069 0076 0020 0069 0064 0022 <.d.i.v. .i.d.".
00a0b598 003c 0064 0069 0076 0020 0069 0064 0022 <.d.i.v. .i.d.".
顺便说一句,这不是UTF-8。看起来像UTF-16。
lkd> s -u nt l10000 "cat"
804dcbec 0063 0061 0074 0069 006f 006e 0050 006f c.a.t.i.o.n.P.o.
804dedfa 0063 0061 0074 0069 006f 006e 0073 0000 c.a.t.i.o.n.s...
804dfa5e 0063 0061 0074 0069 006f 006e 0046 0072 c.a.t.i.o.n.F.r.
804dfb5c 0063 0061 0074 0069 006f 006e 0050 0072 c.a.t.i.o.n.P.r.
lkd> s -u 0 L?10000000 "<div id"
009f582e 003c 0064 0069 0076 0020 0069 0064 0022 <.d.i.v. .i.d.".
009f5924 003c 0064 0069 0076 0020 0069 0064 0022 <.d.i.v. .i.d.".
00a08200 003c 0064 0069 0076 0020 0069 0064 0022 <.d.i.v. .i.d.".
00a0b598 003c 0064 0069 0076 0020 0069 0064 0022 <.d.i.v. .i.d.".