I have never seen something like this before but I assume this is some kind of way C++ allocates dynamic strings. In my decompilation listing in Ghidra I see something like:
local_14 = DAT_00404004 ^ (uint)&stack0xfffffff0; local_70 = 0x2120302e; local_90 = 0x636c6557; uStack140 = 0x20656d6f; uStack136 = 0x45206f74; uStack132 = 0x7972636e; local_6c = 0xa20; local_80 = 0x6f697470; uStack124 = 0x694b206e; uStack120 = 0x76206172; uStack116 = 0x322e342e; local_6a = 0; local_28 = 0x203a656d; plea_str = 0x61656c50; uStack60 = 0x69206573; uStack56 = 0x7475706e; uStack52 = 0x756f7920; local_30 = 0x616e726573752072; local_24 = 0; local_60 = 0x656c500a; uStack92 = 0x20657361; uStack88 = 0x75706e69; uStack84 = 0x6f792074; local_48 = 0x3a64726f; local_50 = 0x7773736170207275; local_20 = 0x656d6f636c65570a; local_44 = 0x20; local_18 = 0x20; local_d0 = 0xa2e6e; local_f0 = 0x6f72570a; uStack236 = 0x7020676e; uStack232 = 0x77737361; uStack228 = 0x2e64726f; local_e0 = 0x656c5020; uStack220 = 0x20657361; uStack216 = 0x20797274; uStack212 = 0x69616761; your_str = 0x72756f59; uStack156 = 0x65737520; uStack152 = 0x6d616e72; uStack148 = 0x203a65; local_c0 = 0x72756f59; uStack188 = 0x73617020; uStack184 = 0x726f7773; uStack180 = 0x203a64; local_b0 = 0x766e490a; uStack172 = 0x64696c61; uStack168 = 0x6d616e20; uStack164 = 0xa2165;
I am not totally sure what
local_14 is doing either. But each of these locals is a string as you can tell from the bytes. Hovering over them gives the string (in reverse). I'd like to find a way to combine these in a way that makes them make more sense but despite my best efforts I cannot type them correct to get ghidra to recognize what they are and their relationship. What is the best way to handle these strings to clean up my decompilation?