Blog

×××
Tinkernut Blog
  • How To Make Your Own Encryption


    ****UPDATE: DOWNLOAD THE PROJECT FILES****

    This video lays out the steps for creating a very simple encryption and decryption program using free tools. The programming language we will be using is VB Script.  See if you can decrypt this text:

    wkjlue#vnrro#huxwxi#uxr\

     

    The code below is for the encrypting program:

    <—–Start copying below this line—–>
    ‘SIMPLE VB ENCRYPTION PROGRAM
    ‘Create a dialogue box that asks for the text to encode
    set x = WScript.CreateObject(“WScript.Shell”)
    mySecret = inputbox(“Enter text to be encoded”)
    ‘Reverse the submitted text
    mySecret = StrReverse(mySecret)
    ‘Open up an instance of Notepad to print the results after waiting for 1 second
    x.Run “%windir%\notepad”
    wscript.sleep 1000
    x.sendkeys encode(mySecret)’This function encodes the text by advancing each character 3 letters
    function encode(s)
    For i = 1 To Len(s)
    newtxt = Mid(s, i, 1)
    newtxt = Chr(Asc(newtxt)+3)
    coded = coded & newtxt
    Next
    encode = coded
    End Function
    <—-Stop copying above this line——>
    <—–Start copying below this line—–>
    ‘SIMPLE VB DECRYPTION PROGRAM
    ‘Create a dialogue box that asks for the text to encode
    set x = WScript.CreateObject(“WScript.Shell”)
    mySecret = inputbox(“Enter text to be encoded”)
    ‘Reverse the submitted text
    mySecret = StrReverse(mySecret)
    ‘Open up an instance of Notepad to print the results after waiting for 1 second
    x.Run “%windir%\notepad”
    wscript.sleep 1000
    x.sendkeys encode(mySecret)’This function encodes the text by advancing each character 3 letters
    function encode(s)
    For i = 1 To Len(s)
    newtxt = Mid(s, i, 1)
    newtxt = Chr(Asc(newtxt)-3)
    coded = coded & newtxt
    Next
    encode = coded
    End Function
    <—-Stop copying above this line——>
    <—–Start copying below this line—–>
    –Applescript encryption program
    set words_to_encrypt to “I want to encrypt sentences. Not just words!”
    set multiplier to 5
    set charList to {“a”, “b”, “c”, “d”, “e”, “f”, “g”, “h”, “i”, “j”, “k”, “l”, “m”, “n”, “o”, “p”, “q”, “r”, “s”, “t”, “u”, “v”, “w”, “x”, “y”, “z”,”A”, “B”, “C”, “D”, “E”, “F”, “G”, “H”, “I”, “J”, “K”, “L”, “M”, “N”, “O”, “P”, “Q”, “R”, “S”, “T”, “U”, “V”, “W”, “X”, “Y”, “Z”, “1”, “2”, “3”,”4″, “5”, “6”, “7”, “8”, “9”, “0”, ” “, “~”, “!”, “@”, “#”, “$”, “%”, “^”, “&”, “*”, “(“, “)”, “_”, “+”, “{“, “}”, “|”, “:”, “\””, “<“, “>”, “?”, “`”, “-“,”=”, “[“, “]”, “\\”, “;”, “‘”, “,”, “.”, “/”, “a”}considering case
    –get a list of numbers for the words corresponding to the item numbers of the characters in charList
    set p_letter_list to text items of words_to_encrypt
    set p_num_list to {}
    repeat with i from 1 to (count of p_letter_list)
    set this_letter to item i of p_letter_list
    repeat with j from 1 to count of charList
    set this_char to item j of charList
    if this_letter is this_char then
    set end of p_num_list to j
    exit repeat
    end if
    end repeat
    end repeat
    –encrypt the numbers
    set modulus to count of charList
    set c_num_list to {}
    repeat with i from 1 to (count of p_num_list)
    set p_num to item i of p_num_list
    set c_num to ((p_num * multiplier) mod modulus)
    set end of c_num_list to c_num
    end repeat
    –get the characters for the encrypted numbers corresponding to the characters in charList
    set c_letter_list to {}
    repeat with i from 1 to (count of c_num_list)
    set this_item to item i of c_num_list
    set end of c_letter_list to (item this_item of charList)
    end repeat
    –coerce the encrypted characters into a string
    set c_string to c_letter_list as string
    end considering
    <—-Stop copying above this line——>
  • Tinkernut streaming live now!


    Tinkernut streaming live now!

    http://www.live.tinkernut.com

    LiveLive

  • GTA3 coming to iOS and Android!


    GTA3 coming to iOS and Android!

    $5 Grand Theft Auto III Hits Android and iOS (Yes, iPhone 4 Too) Next Week

    Grand Theft Auto III: 10 Year Anniversary Edition hits the iPad, iPad 2, iPhone 4, iPhone 4S and a variety of Android devices next week for $4.99, Rockstar said today. Here's a complete run down of th…

  • Who else has lost all confidence in PayPal besides me?


    Who else has lost all confidence in PayPal besides me?

    TechCrunch | After The Regretsy and Diaspora Account Freezes, We’ve Lost Confidence In PayPal

    Hey PayPal, do you realize people no longer trust you? By heartlessly freezing the accounts of legitimate causes, you've shaken our confidence. By releasing the funds only in response to public pressu…

  • Now this is a business card!


    Now this is a business card!

    The Perfect Computer Geek’s Business Card [Image]

    There is nothing quite like an awesome business card that reflects your passions and/or interests…

  • The biggest problem facing future generations…


    Problems facing future generations…

    Future Generations and Screen Names [Comic]

    Geeks are Sexy Technology News. tech, science, news and social issues for geeks. Main menu. Skip to content. Home; Tech Videos; Articles; Cosplay; Store; About us; Contact us. Facebook icon; Twitter i…

  • I can’t wait to start selling Wooly Mammoth rides for $5


    I can't wait to start selling Wooly Mammoth rides for $5

    Scientists Close to Reviving Wooly Mammoths From Extinction

    Some 450 generations after our ancestors armed themselves with sharpened sticks to kill mammoths, scientists are now working to revive them — and they're actually incredibly close to doing it.

  • How to legally rob a bank


    How to legally rob a bank

  • Skyrim on PC + Kinect = OMG I WANT ONE!!!


    Skyrim on PC + Kinect = OMG I WANT ONE!!!

    Skyrim Now Works With Kinect (On PC)

    Look at this guy. He's rigged up a copy of Skyrim to work with Kinect. And it doesn't just work. It works well. Stuff like menu juggling looks like a bit of a pain, as it's slower owing to the necessi…

  • Get Minecraft Pocket Edition (and other cool apps) for 10 cents!


    Get Minecraft Pocket Edition (and other cool apps) for 10 cents!

    10 Billion Downloads! – Android Market

    Shop Android Market on the web. Purchase and enjoy instantly on your Android phone or tablet without the hassle of syncing.