I’d like to print both MSB and LSB of a u16 variable, here is my code: This code just print the LSB part in hexa format, but can you tell me how do I print the MSB part? Answer This code just print the LSB part Well of course, buf[0] = reg; only copies 8 bits. And what result you
Tag: hex
Getting only hexa decimal byte values from the disassembly of a compiled library
I have used objdump to disassemble all the functions in a compiled library file and written the output to a text file. In the text file the output of function called clear_bit is as follows. The output of an another function set_bit is as follows-: Similar to the above two functions, this output.txt contains disassembly of more than 100 such
Decode base64 strings into hex strings in a file and overwrite
I have a list of base64 strings in a file (file.txt) that I need to convert into hex. E.g., Command: This command works individually (albeit the spaces in between), but I need to convert through each string in the file, which has more than 500 lines. Basically, I want the above base64 string format to be decoded to the below
Send and receive Hex String from linux Server C#
I’m developing an developing a little software in c# that connect to a Linux server. the software send a HEX String and receive a HEX String Back. here is my code an example of a string is 0x30 0x30 0x30 0x30 0x30 0x30 0x30 0x34 0x03 0x30 0x30 0x30 and the response is this 30 30 30 30 30 30
Converting User Input Hexadecimal to Decimal in Assembly
I am trying to create an assembly program that takes a user input hexadecimal number no greater than 4 digits and outputs the same number in base 10. This is being done using NASM on a Linux install. Using some tutorials I’ve found and my very limited understanding of this language, I have come up with this. It should be
hex code implementation for spawning a shell
I am trying to implement the codes given in smashing the stack for fun and profit by Aleph to learn the basics of buffer overflow attacks. Machine architecture: Ubuntu 12.10 64 bit programs compiled using -m32 flag in gcc So far, I have managed to spawn a shell using the assembly instructions. The next step is to convert those instructions
How to insert an offset to hexdump with xxd?
Is there an easy way to add an offset to the hex dump generated by xxd ? i.e instead of I should get Answer This is what I am doing now..It works perfectly but its kind of lame approach for just adding an offset 🙂