diff options
author | Aleksey Veresov <aleksey@veresov.pro> | 2020-10-16 22:38:45 +0300 |
---|---|---|
committer | Aleksey Veresov <aleksey@veresov.pro> | 2020-10-16 22:38:45 +0300 |
commit | a5ada20d77f6fcf7bf54e49402e55d3b1c56df5e (patch) | |
tree | b6f9a205a4da8c00c58b5da66c74b99874f4f620 /cipher.sts | |
parent | ce9e52469d0b12b3231ccc199e1b19bb924f54cd (diff) | |
download | cryptrobber-a5ada20d77f6fcf7bf54e49402e55d3b1c56df5e.tar cryptrobber-a5ada20d77f6fcf7bf54e49402e55d3b1c56df5e.tar.xz cryptrobber-a5ada20d77f6fcf7bf54e49402e55d3b1c56df5e.zip |
Meh.
Diffstat (limited to 'cipher.sts')
-rw-r--r-- | cipher.sts | 24 |
1 files changed, 8 insertions, 16 deletions
@@ -1,18 +1,10 @@ -; cipher is password string (pointer to start and length) and position in it - -defword ciphernew - 0 -exit - -defword mod - swap / drop -exit - -defword cipher ; ... passwd plen ppos key - 3 get 2 get + @ xor ; key = key ^ passwd[ppos] - over 1 + 3 get mod 2 set ; ppos = (ppos + 1) % plen -exit - -defword cipherdel +defword cipher + 3 ref as byte + 2 get as password + 1 get as plen + 0 get as pos + pos @ password + @ byte @ xor byte ! + pos @ 1 + pos ! + pos @ plen = if 0 pos ! fi drop drop drop exit |