diff options
| author | Julian Blake Kongslie | 2020-05-24 23:02:20 -0700 |
|---|---|---|
| committer | Julian Blake Kongslie | 2020-05-24 23:55:52 -0700 |
| commit | 2379a457a87afc9507f0f2a9664fcb47006a2aa2 (patch) | |
| tree | b2911f06721ce3b2cca269af3b2782747478f527 /ssh/run | |
| parent | Initial commit. (diff) | |
| download | magisk-ssh-2379a457a87afc9507f0f2a9664fcb47006a2aa2.tar.xz | |
Diffstat (limited to '')
| -rwxr-xr-x | ssh/run | 18 |
1 files changed, 18 insertions, 0 deletions
| @@ -0,0 +1,18 @@ | |||
| 1 | #!/system/xbin/bash -l | ||
| 2 | |||
| 3 | SSHD="$(which sshd)" | ||
| 4 | |||
| 5 | while true; do | ||
| 6 | |||
| 7 | nohup "$SSHD" \ | ||
| 8 | -D \ | ||
| 9 | -f "$MODDIR"/ssh/sshd_config \ | ||
| 10 | -h "$MODDIR"/ssh/ssh_host_rsa_key \ | ||
| 11 | -o "AuthorizedKeysFile $MODDIR/ssh/authorized_keys" \ | ||
| 12 | -o "ForceCommand $MODDIR/ssh/setup-connection" \ | ||
| 13 | > /dev/null & | ||
| 14 | wait | ||
| 15 | |||
| 16 | sleep 1 | ||
| 17 | |||
| 18 | done | ||
