Git Product home page Git Product logo

backdoor's Introduction

About

This is just a simple SSH server (mostly for testing/diagnostic purposes). For example, if you have a rooted Android and you want to quickly get SSH access to it, this backdoor is an easy solution.

Quick start

Build for ARM64

git clone https://github.com/xaionaro-go/backdoor
cd backdoor
CGO_ENABLED=0 GOARCH=arm64 go build

Upload to a smartphone

adb push backdoor /sdcard/Download/
adb shell 'su -c "mkdir -p /data/backdoor; mv /sdcard/Download/backdoor /data/backdoor/; chmod +x /data/backdoor/backdoor"'

Launch the backdoor

adb push ~/.ssh/id_ed25519.pub /sdcard/Download/authorized_keys
adb shell 'su -c "/data/backdoor/backdoor /bin/sh 0.0.0.0:8022 /sdcard/Download/authorized_keys"' &

Get the IP address

PHONE_ADDR="$(adb shell ip a show dev wlan0 | grep 'inet ' | tr "/" " " | awk '{print $2}')"

Login

ssh -p 8022 "$PHONE_ADDR"

backdoor's People

Contributors

xaionaro avatar

Stargazers

Dreamer avatar

Watchers

 avatar

backdoor's Issues

Interesting project

This is not an issue just wanted to get in touch. I need similar solution for packer.
The problem:
In this project after building the Vmware or Virtual Box images the script has to ssh to the machine and start performing actions inside. Apparently GO removed rsa/dss in the code so I am getting:

SSH handshake err: ssh: handshake failed: EOF

The server inside the Vmware macOS supports:

PORT   STATE SERVICE VERSION
22/tcp open  ssh     OpenSSH 6.2 (protocol 2.0)
| ssh2-enum-algos: 
|   kex_algorithms: (4)
|       diffie-hellman-group-exchange-sha256
|       diffie-hellman-group-exchange-sha1
|       diffie-hellman-group14-sha1
|       diffie-hellman-group1-sha1
|   server_host_key_algorithms: (2)
|       ssh-rsa
|       ssh-dss
|   encryption_algorithms: (15)
|       aes128-ctr
|       aes192-ctr
|       aes256-ctr
|       arcfour256
|       arcfour128
|       [email protected]
|       [email protected]
|       aes128-cbc
|       3des-cbc
|       blowfish-cbc
|       cast128-cbc
|       aes192-cbc
|       aes256-cbc
|       arcfour
|       [email protected]
|   mac_algorithms: (19)
|       [email protected]
|       [email protected]
|       [email protected]
|       [email protected]
|       [email protected]
|       [email protected]
|       [email protected]
|       [email protected]
|       [email protected]
|       hmac-md5
|       hmac-sha1
|       [email protected]
|       [email protected]
|       hmac-sha2-256
|       hmac-sha2-512
|       hmac-ripemd160
|       [email protected]
|       hmac-sha1-96
|       hmac-md5-96
|   compression_algorithms: (2)
|       none
|_      [email protected]

Is there a way I can use this project to make ssh communicating with a key?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.