Browse Source

Added shell, python test programs for comparision (Ca)

tags/v0.2
mrbesen 2 years ago
parent
commit
d95f4dd71a
3 changed files with 28 additions and 1 deletions
  1. 4
    1
      README.md
  2. 10
    0
      crack.py
  3. 14
    0
      crack.sh

+ 4
- 1
README.md View File

@@ -11,11 +11,14 @@ Host defaults to "127.0.0.1" and port default to "5454".
ctl + c to stop

## Start a Server
Warning: Server needs a HUGE amount of RAM!
```
java -jar Server.jar [c:classname] [p:port]
java -jar -Xmx 6G -Xms 1G Server.jar [c:classname] [p:port]
```
classname default to "Test" and is the class thats loaded to generate Jobs.
port defaults to "5454".

to stop enter "stop" into the console.
Force Stop: ctl + c

crack.py and crack.sh need much ram.

+ 10
- 0
crack.py View File

@@ -0,0 +1,10 @@
#!/bin/python
public=14012539
mod=4862802614
step = mod / 100
for j in range(0, 100):
print "Testing from", step*j, " to ", step*(j+1), " (", j, "%)"
for i in range(j*step, (j+1)*step):
if (( i * public ) % mod) == 1:
print i
break

+ 14
- 0
crack.sh View File

@@ -0,0 +1,14 @@
#!/bin/bash
public="14012539"
mod="4862802614"
for i in `seq 1 $mod`
do
let out=( $i * $public ) % $mod
if [ $out == 1 ]
then
echo "$i true"
exit 0
else
echo "$i false"
fi
done

Loading…
Cancel
Save