1
0
mirror of git://f0xx.org/android_cast synced 2026-07-29 04:38:53 +03:00
Files
android_cast/examples/rssh/linux-sim
2026-06-15 11:56:23 +02:00
..
2026-06-15 11:56:23 +02:00
2026-06-15 11:56:23 +02:00

Linux RSSH device/operator simulation

Simulates the Android RSSH path on a laptop with real OpenSSH client + optional local sshd.

Prerequisites

  • curl, jq, sshpass (for non-interactive sim)
  • Backend reachable (CRASHES_BASE or default from ra_lib.sh)
  • Admin whitelist + open session for the simulated device_id

Device sim (heartbeat + reverse forward)

export CRASHES_BASE="http://cast01.intra.raptor.org/app/androidcast_project/crashes"
export RA_DEVICE_ID="linux-rssh-lab-01"

# 1) First run registers heartbeat (wait)
./ra_device_sim.sh

# 2) Whitelist device + open session in admin UI, then:
export RA_SKIP_ADMIN=1
./ra_device_sim.sh

Operator sim (on bastion / BE)

After device sim prints REMOTE_BIND_PORT and username:

./ra_operator_connect.sh 18022 ra-SESSIONID shell
./ra_operator_connect.sh 18022 ra-SESSIONID sftp

Android parity

Android Linux sim
RemoteAccessService poll ra_ra_post via ra_lib.sh
RsshLocalSshServer :8022 local sshd -p 8022
ReverseSshTunnelBridge JSch -R ssh -N -R …

See REMOTE_ACCESS_IMPL.md and 20260602_REVERSE_SSH_proposals_summary.md.