diff options
-rw-r--r-- | Makefile | 11 | ||||
-rw-r--r-- | encrypt.sts | 2 | ||||
-rw-r--r-- | ia32/stack.sts | 2 | ||||
-rw-r--r-- | main.sts | 5 |
4 files changed, 11 insertions, 9 deletions
@@ -1,9 +1,14 @@ -.PHONY: cryptrobber clean +all: cryptrobber encrypt +.PHONY: all clean encrpyt cryptrobber -cryptrobber: +cryptrobber: smack strans ./smack main.sts | ./strans > $@ chmod 0755 $@ +encrypt: smack strans + ./smack encrypt.sts | ./strans > $@ + chmod 0755 $@ + smack: smack.c gcc $< -o $@ @@ -11,4 +16,4 @@ strans: strans.c gcc $< -o $@ clean: - rm -f smack strans cryptrobber + rm -f smack strans cryptrobber encrypt diff --git a/encrypt.sts b/encrypt.sts index 378a686..8112d9b 100644 --- a/encrypt.sts +++ b/encrypt.sts @@ -2,7 +2,7 @@ module ia32/elf/begin.sts module cipher.sts defword encbyte - key dup if + sys_read dup if drop cipher 1 1 diff --git a/ia32/stack.sts b/ia32/stack.sts index cf1bd21..7756706 100644 --- a/ia32/stack.sts +++ b/ia32/stack.sts @@ -13,7 +13,7 @@ next defasm drop # 58 ?' ; pop eax next - + defasm dup # ff ?' # 34 ?' # 24 ?' ; push dword [esp] next @@ -3,9 +3,6 @@ module ia32/elf/begin.sts set_entry 30 31 32 33 0 set 34 1 set 35 2 set - emit - emit - emit -quit +sys_exit module ia32/elf/end.sts |