NishanthMenon changed the topic of #openocd to: this is the place to discuss all things OpenOCD | Logs: https://libera.irclog.whitequark.org/openocd/
tsal has quit [Ping timeout: 268 seconds]
akaWolf has quit [Ping timeout: 272 seconds]
tsal has joined #openocd
akaWolf has joined #openocd
thinkfat_ has joined #openocd
thinkfat has quit [Ping timeout: 268 seconds]
tchebb_ has quit [*.net *.split]
ericonr has quit [*.net *.split]
nathanhi has quit [*.net *.split]
tchebb has joined #openocd
ericonr has joined #openocd
nathanhi has joined #openocd
bq has quit [*.net *.split]
extor has quit [*.net *.split]
bencoh has quit [*.net *.split]
Bertl_zZ has quit [*.net *.split]
keesj1 has quit [*.net *.split]
mawk has quit [*.net *.split]
xantoz has quit [*.net *.split]
Flecks has quit [*.net *.split]
bencoh has joined #openocd
Bertl_zZ has joined #openocd
extor has joined #openocd
xantoz has joined #openocd
keesj1 has joined #openocd
Fleck has joined #openocd
bq has joined #openocd
mawk has joined #openocd
diddly has quit [Ping timeout: 272 seconds]
diddly has joined #openocd
nerozero has joined #openocd
Haohmaru has joined #openocd
diddly has quit [Ping timeout: 264 seconds]
diddly has joined #openocd
Guest0 has joined #openocd
<Guest0> hi!
<Guest0> i have just developed a caesar cipher program on my stm32f429 device. the key in the device is "3" and i would like to extract this key from my device. i think i need to get a memory dump of my device. so, can you tell me the potential scenarios for extracting the secret key from my board? how can i do it? (im also open for your resource
<Guest0> suggestions), thanks a lot!
<olerem> Guest0: create memory dump and flush dump. use radare2 to extract the key
bencoh has joined #openocd
bencoh has quit [Changing host]
<Guest0> olerem as i understand radare2 is a tool to analyze bin files. but, how can i dump memory of any device?
Error403 has joined #openocd
<Haohmaru> "of any device" is too broad, for that particular chip one way is via SWD debugger
<Haohmaru> where's the data you wanna get? in the RAM or in the flash?
Bugies has joined #openocd
<Guest0> Haohmaru I defined the secret key in an int variable, so i think its in RAM
<Haohmaru> an int variable may be in RAM or flash or both, depends on how you compile and build the thing
<Haohmaru> if it's in flash, it may be enough to use the .elf and radare2 to find it
<Haohmaru> if it's in RAM - debugger
Guest0 has quit [Ping timeout: 252 seconds]
Error403 has quit [Quit: Leaving]
nerozero has quit [Remote host closed the connection]
nerozero has joined #openocd
Bertl_zZ is now known as Bertl
Guest0 has joined #openocd
<Guest0> Haohmaru which debugger can i use? and how to use .elf and radare2 :')  when i read blog post about radare2 i see this command: "radare2 file.exe" but do not have a binary
<PaulFertser> Guest0: are you a student?
<PaulFertser> Guest0: you can use same debugger you're using to flash the stm32 part
<Guest0> yes i am
<PaulFertser> Guest0: since you have the source code I suggest you do objdump -S to see how your code translates into assembly and where exactly that key is stored and how it's handled.
<Guest0> umm yes i know that i can use ST Utility program to inspect memory. But it will only work for STM devices, i would like to gain experience on reversing on embedded devices
<PaulFertser> Guest0: we're on OpenOCD channel, so for get the proprietary utility.
<Guest0> PaulFertser is it possible to dump the memory with OpenOCD? If so, how can I do it
<Haohmaru> Guest0 the .elf *is* the binary/exe
<Haohmaru> your compiler most-probably spits out an .elf
<Guest0> Haohmaru ok sir but i will think like it is not my device. Please assume i am reversing a foreign board. I still have the source code, but an reverse engineer will not have my codes (and .elf output of compiler) - thats why i do not want to use STM softwares like ST Utility
<Guest0> how could I see the secret key in memory if it would not my device and I would not have the elf output?
<Xogium> the whole point of secret key is, well.. Hopefully its stored in some secure storage, be it memory or otherwise, so I don't think you could see it so easily if at all
<Guest0> actually it is not a secret key sir, i just defined the key by an integer variable and its probably stored in flash
<Guest0> openocd -f interface/stlink-v2.cfg -f target/stm32f1x.cfg -c "init" -c "reset init" -c "flash read_bank 0 firmware.bin 0 0x8000" -c "exit"
<Guest0> does this command help me to dump the memory? o.O
<PaulFertser> Guest0: there's the official User Manual, it lists "dump_image" command.
<PaulFertser> Guest0: dump_image works for any memory-mapped resource.
<Guest0> oh, i will look at this command, thank you sir
Guest0 has quit [Quit: Client closed]
emacs_pprentice_ has quit [Quit: Leaving]
wingsorc has joined #openocd
Bertl is now known as Bertl_oO
wingsorc has quit [Quit: Leaving]
wingsorc has joined #openocd
indy has quit [Quit: ZNC 1.8.2 - https://znc.in]
indy has joined #openocd
indy has quit [Ping timeout: 240 seconds]
HelloShitty has quit [Ping timeout: 268 seconds]
indy has joined #openocd
Hawk777 has joined #openocd
HelloShitty has joined #openocd
Haohmaru has quit []
lh has quit [Remote host closed the connection]
lh has joined #openocd
lh has quit [Remote host closed the connection]
lh has joined #openocd
noperator[m] has joined #openocd
lh has quit [Write error: Broken pipe]
lh has joined #openocd
dliviu has quit [Quit: Going away]
dliviu has joined #openocd
nerozero has quit [Ping timeout: 264 seconds]
zjason` has joined #openocd
zjason has quit [Read error: Connection reset by peer]
Steffann is now known as Steffanx
sbach has quit [Read error: Connection reset by peer]
sbach has joined #openocd
Bugies has quit [Ping timeout: 272 seconds]
wingsorc has quit [Quit: Leaving]
crabbedhaloablut has joined #openocd
akaWolf has quit [Ping timeout: 268 seconds]
akaWolf has joined #openocd
wingsorc has joined #openocd