Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
FieldView encryption challenge
#21
Quote:z!re, i had a link at the top of my post to a static lib version... :roll: :lol: Big Grin :wink:
:oops: I overlooked the .a file Tongue

Neo, VBC?
Reply
#22
Quote:Neo, VBC?
Yes Zire, it's a headerless compression algorithm which I also wrote for NeoCL, but then it was in QB. I'm thinking of implementing that too so that your packages get smaller.
Reply
#23
btw, what's a julius caesar?
ttp://m0n573r.afraid.org/
Quote:quote: "<+whtiger> you... you don't know which way the earth spins?" ... see... stupidity leads to reverence, reverence to shakiness, shakiness to... the dark side
...phear
Reply
#24
In the Roman age, Julius Caesar used encryption to send messages to the warfront commanders without them being readable to anyone else.

He used the encryption where each character is converted to a character n letters away from it. In which n was a static number that differed for each commander he wrote to so that the commanders couldn't read eachother's letters to Caesar.
The simplest known Caesar encryption is the +1 Caesar, which works like:
HELLO
to:
IFMMP
(all letters are +1 letter further).
Reply
#25
XD..... Oops,. :lol: .. that's what I just did....
Kevin (x.t.r.GRAPHICS)

[Image: 11895-r.png]
Reply
#26
:o
:lol:
ttp://m0n573r.afraid.org/
Quote:quote: "<+whtiger> you... you don't know which way the earth spins?" ... see... stupidity leads to reverence, reverence to shakiness, shakiness to... the dark side
...phear
Reply
#27
Tongue Laugh it up... I did say it was my first go,.. I normaly do the oppisite with HTML or OBJ files... tho it doesn't really count.. those are easy...

Try try agian: This one displaces/encrypts the message acording to a password, then to top it off, rewrites the whole thing backward... makes a reall mess of things, but it cleans up good,.. never fear... :lol: ... If it usless, the sub routines are at least comical... Big Grin

Code:
DECLARE SUB ScrewUpMessage( MSG$, PASS$ )
DECLARE SUB FixUpMessage( MSG$, PASS$ )

'#######################################
MSG$ = "Hello, world. This is a better encrypter that not only scrambles to a given password, it reverses the encrypted message. ^_^,.."
PASS$ = "MyPassword"

PRINT "Message: "; MSG$
SLEEP
PRINT
ScrewUpMessage( MSG$, PASS$ )
PRINT "Encryption: "; MSG$
PRINT
SLEEP
FixUpMessage( MSG$, PASS$ )
PRINT "Decryption: "; MSG$
SLEEP
'######################################

SUB ScrewUpMessage( MSG$, PASS$ )
    NUM = LEN(PASS$)
    DIM CCard(NUM)
    FOR i = 1 TO NUM
        A$ = MID$(PASS$, i, 1)
        CCard(i) = ASC(A$)
    NEXT
    Cont = 0
    FOR i = 1 TO LEN(MSG$)
        cont = (cont + 1)MOD NUM
        IF cont = 0 THEN cont = 1
        B$ = MID$(MSG$, i, 1)
        LNUM = ASC(B$)
        C$ = STR$(LNUM + CCard(cont))
        STORE$ += CHR$(VAL(C$))
    NEXT
    
    Cont = LEN(STORE$)
    FOR i = 1 TO LEN(STORE$)
        D$ = MID$(STORE$, cont, 1)
        RSTORE$ += D$
        Cont -= 1
        IF Cont = 0 THEN EXIT FOR
    NEXT
    MSG$ = RSTORE$
    STORE$ = ""
    RSTORE$ = ""
END SUB

SUB FixUpMessage( MSG$, PASS$ )
    NUM = LEN(PASS$)
    DIM CCard(NUM)
    FOR i = 1 TO NUM
        A$ = MID$(PASS$, i, 1)
        CCard(i) = ASC(A$)
    NEXT
    
    Cont = LEN(MSG$)
    FOR i = 1 TO LEN(MSG$)
        D$ = MID$(MSG$, cont, 1)
        STORE$ += D$
        Cont -= 1
        IF Cont = 0 THEN EXIT FOR
    NEXT
    
    Cont = 0
    FOR i = 1 TO LEN(STORE$)
        cont = (cont + 1)MOD NUM
        IF cont = 0 THEN cont = 1
        B$ = MID$(STORE$, i, 1)
        LNUM = ASC(B$)
        C$ = STR$(LNUM - CCard(cont))
        RSTORE$ += CHR$(VAL(C$))
    NEXT
    
    MSG$ = RSTORE$
    STORE$ = ""
    RSTORE$ = ""
END SUB
Kevin (x.t.r.GRAPHICS)

[Image: 11895-r.png]
Reply
#28
Quote:So you must have a time machine.

And thus I must be the most intelligent person in the entire world anyway, and so could always just write a superior encryption routine. MUUWAHAHAHAHAHAHAHAH!

But no time for that! Now I must go and service the TM1000. The flux capacitors need cleaning out and the quark filters need replaced.
Reply
#29
Quote:superior encryption routine.
Then do it Tongue
Yours is also a julius/caesar encryption... very superior Wink


Also:
People, what happens when the password given is longer than the message, is that taken into consideration?
Reply
#30
it is with mine :wink:
ttp://m0n573r.afraid.org/
Quote:quote: "<+whtiger> you... you don't know which way the earth spins?" ... see... stupidity leads to reverence, reverence to shakiness, shakiness to... the dark side
...phear
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)