Posts Tagged ‘C’

Reverseme: Namegenme

Sunday, June 13th, 2010 by webstersprodigy

This guy is here: http://crackmes.de/users/moofy/moofys_namegenme/ namegenme.zip I had a fairly hard time with this one for some reason, although the solution was right in front of my face… Most the logic for calculating the generation is in the function 00401852. The Serial is stored in a global variable, and the name is generated by taking [...]

execv-like system call

Tuesday, June 30th, 2009 by webstersprodigy

From the system man page, it explicitely says: Do not use system() from a program with set-user-ID or set-group-ID privileges, because strange values for some environment variables might be used to subvert system integrity. Since system is basically a fork and wait, it’s pretty easy to use execv instead. Here is a snippet from the [...]

playing a scale with the atmega16

Monday, May 4th, 2009 by webstersprodigy

A musical “note” is a waveform that has a certain fundamental frequency. A perfect sine wave consists only of the fundamental frequency, and sounds very “pure” or mellow, like a flute. For this project, you are to use interrupts to generate the notes of a musical scale, while at the same time using another interrupt to update a count. We will generate square waves by toggling a bit within a port on and off. Specifically, your program should play the notes from middle C to the next higher C, each of approximately one second in duration. These notes should be playing at the same time that an 8-bit binary count is being displayed in the LED’s, updating at approximately 1/4 second.


No computers were harmed in the 0.269 seconds it took to produce this page.