Thread: Obfuscated Code Contest

  1. #1

    Obfuscated Code Contest

    Obfuscated Code Contest

    Schedule / Deadline
    Start Date: January 3rd, 2005
    End Date: Febuary 1st, 2005

    Submissions
    If you choose to enter, please reply stating that you have entered the contest, and before the Contest deadline you must enter a submission that meets the stated requirements and send it to the submission officer via email or private message. E-mail is preferred.

    E-mail: [email protected]
    PM: Stack Overflow

    Introduction
    Obfuscated code is source code that is very hard to read and understand. Some languages are more prone to obfuscation than others. C, C++ and Perl are most often cited as easily obfuscatable languages. Macro preprocessors are often used to create hard to read code by masking the standard language syntax and grammar from the main body of code.

    Obfuscated code has its advantages and disadvantages. For instance it minimizes code size though, however, is extremely difficult to debug.

    Details
    Create a Hello World program using obfuscated code. Your code will be judged not based upon code size, but rather your creativity.
    Bonus [5 points]: Explain your obfuscated code in detail. For instance, what block of your obfuscated code executes which part your program.


    Contest Rules
    Below are the current contest rules and regulations.

    I. Official Rules
    I.I You may only submit one entry per contest, and it must have been submitted between the contest start and end dates.

    I.II Entries submitted should be:
    • Substantially the developer's original design
    • Substantially the developer's original programming
    II. Code Judging
    II.I Submitted code will be judged based on the following:

    Compiliation (0 - 5)
    How easy it is to compile. And if it compiles on multi-platform.

    Ingenuity (0 - 10)
    This will be graded depending upon if you have created this code yourself, or have used other sources to compile your code.

    Efficiency (0 - 5)
    Code efficiency, how can it be used in a program. Is it usable or just fancy. (Are processes closed when finished, do you use arrays when initializing multiple variables under one instance, and do you free memory after allocation?)

    Best Code Score: 20


    - Stack Overflow
    Last edited by Stack Overflow; 01-03-2005 at 04:40 PM. Reason: Changed info.
    Segmentation Fault: I am an error in which a running program attempts to access memory not allocated to it and core dumps with a segmentation violation error. This is often caused by improper usage of pointers, attempts to access a non-existent or read-only physical memory address, re-use of memory if freed within the same scope, de-referencing a null pointer, or (in C) inadvertently using a non-pointer variable as a pointer.

  2. #2
    & the hat of GPL slaying Thantos's Avatar
    Join Date
    Sep 2001
    Posts
    5,681
    IMO obfuscated code contests are better if all the program entries have the same end result. IE the 12 days of christmas contest from 2003

  3. #3
    I agree,

    In this case, I have changed the contest slightly. Everyone is now to write a Hello World program using obfuscated code. The obfuscated code can be short or long. Remember, the code is judged by creativity none-the-less.


    - Stack Overflow
    Segmentation Fault: I am an error in which a running program attempts to access memory not allocated to it and core dumps with a segmentation violation error. This is often caused by improper usage of pointers, attempts to access a non-existent or read-only physical memory address, re-use of memory if freed within the same scope, de-referencing a null pointer, or (in C) inadvertently using a non-pointer variable as a pointer.

  4. #4
    & the hat of GPL slaying Thantos's Avatar
    Join Date
    Sep 2001
    Posts
    5,681
    Opps sorry I missed the hello world part

  5. #5
    Sweet
    Join Date
    Aug 2002
    Location
    Tucson, Arizona
    Posts
    1,820
    What do you mean by hello world just a simple hello world to the console or just like a rudimentry app? eg. add two numbers, fahrenheit to celcuis etc..
    Woop?

  6. #6
    Cat without Hat CornedBee's Avatar
    Join Date
    Apr 2003
    Posts
    8,895
    I'm in. Let's get coding
    All the buzzt!
    CornedBee

    "There is not now, nor has there ever been, nor will there ever be, any programming language in which it is the least bit difficult to write bad code."
    - Flon's Law

  7. #7
    Hello,

    prog-bman: By "Hello World!" I mean actually coding it as obfuscated as possible. Enough that you wouldn't even realize it produces and prints Hello World! until executed.

    Edit: I'll keep this contest a bit simple for now. I might make a Part 2 later with more advanced techniques. Besides, I want to see how obfuscated something as simple as Hello World can be.

    CornedBee: Let the games begin!


    - Stack Overflow
    Last edited by Stack Overflow; 01-03-2005 at 05:49 PM.
    Segmentation Fault: I am an error in which a running program attempts to access memory not allocated to it and core dumps with a segmentation violation error. This is often caused by improper usage of pointers, attempts to access a non-existent or read-only physical memory address, re-use of memory if freed within the same scope, de-referencing a null pointer, or (in C) inadvertently using a non-pointer variable as a pointer.

  8. #8
    Registered User
    Join Date
    Dec 2004
    Posts
    465
    How might I go about writing obfuscated code? I don't exactly understand how to make it hard to read.

  9. #9
    Registered User
    Join Date
    Aug 2003
    Posts
    1,218
    Can we assume that all OS's you will try the code on use ASCII system??

  10. #10
    Cat without Hat CornedBee's Avatar
    Join Date
    Apr 2003
    Posts
    8,895
    Does it have to print the literal string "Hello, World!" or does something that can be read as it (ASCII art) suffice?
    All the buzzt!
    CornedBee

    "There is not now, nor has there ever been, nor will there ever be, any programming language in which it is the least bit difficult to write bad code."
    - Flon's Law

  11. #11
    VA National Guard The Brain's Avatar
    Join Date
    May 2004
    Location
    Manassas, VA USA
    Posts
    903
    cool contest.. i'm in


    I think the fun part would be seeing everyone's ideas when the contest is over.

    (author permitting)
    • "Problem Solving C++, The Object of Programming" -Walter Savitch
    • "Data Structures and Other Objects using C++" -Walter Savitch
    • "Assembly Language for Intel-Based Computers" -Kip Irvine
    • "Programming Windows, 5th edition" -Charles Petzold
    • "Visual C++ MFC Programming by Example" -John E. Swanke
    • "Network Programming Windows" -Jones/Ohlund
    • "Sams Teach Yourself Game Programming in 24 Hours" -Michael Morrison
    • "Mathmatics for 3D Game Programming & Computer Graphics" -Eric Lengyel

  12. #12
    Hello,

    To answer your questions:

    Quote Originally Posted by cerin
    How might I go about writing obfuscated code? I don't exactly understand how to make it hard to read.
    » Obfuscated code, for instance, looks like this in general. To best describe Obfuscated code, I would say it is a "concealment of evidence" and harder to "reverse engineer".

    Quote Originally Posted by Shakti
    Can we assume that all OS's you will try the code on use ASCII system??
    » Well, as of the moment, I believe the answer is yes. Just use standard C functions and calls and it should compile without a problem on any C compiler.

    Quote Originally Posted by CornedBee
    Does it have to print the literal string "Hello, World!" or does something that can be read as it (ASCII art) suffice?
    » It can be done either way. ASCII art is cool, and I would definetly have to give extra bonus points for that.

    Quote Originally Posted by The Brain
    cool contest.. i'm in


    I think the fun part would be seeing everyone's ideas when the contest is over.

    (author permitting)
    » Sounds like a good idea. This way we can all see multiple ways to making a Hello World program.


    - Stack Overflow
    Segmentation Fault: I am an error in which a running program attempts to access memory not allocated to it and core dumps with a segmentation violation error. This is often caused by improper usage of pointers, attempts to access a non-existent or read-only physical memory address, re-use of memory if freed within the same scope, de-referencing a null pointer, or (in C) inadvertently using a non-pointer variable as a pointer.

  13. #13
    & the hat of GPL slaying Thantos's Avatar
    Join Date
    Sep 2001
    Posts
    5,681
    I'm in

  14. #14
    Registered User
    Join Date
    Aug 2003
    Posts
    1,218
    Im in (I hope )

  15. #15
    Sweet
    Join Date
    Aug 2002
    Location
    Tucson, Arizona
    Posts
    1,820
    Im in also
    Woop?

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. True ASM vs. Fake ASM ????
    By DavidP in forum A Brief History of Cprogramming.com
    Replies: 7
    Last Post: 04-02-2003, 04:28 AM
  2. Seems like correct code, but results are not right...
    By OmniMirror in forum C Programming
    Replies: 4
    Last Post: 02-13-2003, 01:33 PM
  3. Interface Question
    By smog890 in forum C Programming
    Replies: 11
    Last Post: 06-03-2002, 05:06 PM