Skip to content

RNDIS config

Christian edited this page Aug 24, 2023 · 13 revisions

Device options

sshd: IPv4 only

Uncomment line in file /etc/ssh/sshd_config

ListenAddress 0.0.0.0

And restart SSH daemon: /etc/init.d/sshd restart

Do not close the SSH connection before testing a new connection!

telnetd: IPv4 only

[?]

Disable dnsmasq

[?]

Block public IPv6 access

vi /etc/init.d/firewall
#!/bin/sh
set -e

case "$1" in
    start)
        ip6tables -I INPUT -i rmnet_data0 -j DROP
        ;;
    stop)
        ip6tables -D INPUT -i rmnet_data0 -j DROP
        ;;
    restart)
        $0 stop
        $0 start
        ;;
    *)
        echo "Usage: $0 {start|stop}"
        exit 1
        ;;
esac

exit 0
chmod +x /etc/init.d/firewall
update-rc.d -v firewall defaults
/etc/init.d/firewall start

Change root password

passwd

Misc options

Auto connect

echo "select * from Connection where items = 'ConnMode';" | sqlite3 /jrd-resource/resource/sqlite3/user_info.db3
ConnMode|0
echo "update Connection set value = 1 where items = 'ConnMode';" | sqlite3 /jrd-resource/resource/sqlite3/user_info.db3
echo "select * from Connection where items = 'ConnMode';" | sqlite3 /jrd-resource/resource/sqlite3/user_info.db3
ConnMode|1

(And reboot the device!)

IPv4/IPv6

  • 0 = IPv4 only
  • 2 = IPv6 only
  • 3 = Dual stack
echo "select * from jrd_profile_cfg where items = 'DefaultIpType';" | sqlite3 /jrd-resource/resource/sqlite3/user_info.db3
DefaultIpType|3
echo "update jrd_profile_cfg set value = 0 where items = 'DefaultIpType';" | sqlite3 /jrd-resource/resource/sqlite3/user_info.db3
echo "select * from jrd_profile_cfg where items = 'DefaultIpType';" | sqlite3 /jrd-resource/resource/sqlite3/user_info.db3
DefaultIpType|0

(And reboot the device!)

Profiles

Profile files: /jrd-resource/resource/profile/create/profileXX where XX is {02..16}

name:<Profile name>
apn:<APN>
user:<Username>
psw:<Password>
dial:<Dial number>
protocol:<Protocol>

Protocols

  • 0 = NONE
  • 1 = PAP
  • 2 = CHAP
  • 3 = PAP & CHAP

Default profile

Stored at: /jrd-resource/resource/sqlite3/user_info.db3 (table jrd_profile_cfg)

  • items = DefaultProfileFilename
  • value = profileXX

Predefined profiles

https://en.wikipedia.org/wiki/Public_land_mobile_network#PLMN_code

  • jrd-resource/resource/profile/match/<PLMN>
  • jrd-resource/resource/profile/cust/<PLMN>

Example profiles

/jrd-resource/resource/profile/cust/23201

name:A1
apn:a1.net
protocol:3
dial:*99#
user:[email protected]
psw:ppp

/jrd-resource/resource/profile/cust/23201_A1

name:A1
apn:a1.net
protocol:3
dial:*99#
user:[email protected]
psw:ppp

/jrd-resource/resource/profile/cust/23203

name:T-mobile internet
apn:gprsinternet
protocol:0
dial:*99#

/jrd-resource/resource/profile/cust/23205

name:drei.at
apn:drei.at
protocol:0
dial:*99#

/jrd-resource/resource/profile/cust/23207

name:tele.ring web
apn:web
protocol:0
dial:*99#

/jrd-resource/resource/profile/cust/23207718

name:0677 web
apn:webaut
protocol:1
dial:*99#

/jrd-resource/resource/profile/cust/23207760

name:0677 web
apn:webaut
protocol:1
dial:*99#

/jrd-resource/resource/profile/cust/23207761

name:0677 web
apn:webaut
protocol:1
dial:*99#

/jrd-resource/resource/profile/cust/23207762

name:0677 web
apn:webaut
protocol:1
dial:*99#

/jrd-resource/resource/profile/cust/23207763

name:0677 web
apn:webaut
protocol:1
dial:*99#

/jrd-resource/resource/profile/cust/23207764

name:0677 web
apn:webaut
protocol:1
dial:*99#

/jrd-resource/resource/profile/cust/23207765

name:0677 web
apn:webaut
protocol:1
dial:*99#

/jrd-resource/resource/profile/cust/23207766

name:0677 web
apn:webaut
protocol:1
dial:*99#

/jrd-resource/resource/profile/cust/23207767

name:0677 web
apn:webaut
protocol:1
dial:*99#

/jrd-resource/resource/profile/cust/23207768

name:0677 web
apn:webaut
protocol:1
dial:*99#

/jrd-resource/resource/profile/cust/23207769

name:0677 web
apn:webaut
protocol:1
dial:*99#

/jrd-resource/resource/profile/cust/23207799

name:0677 web
apn:webaut
protocol:1
dial:*99#

/jrd-resource/resource/profile/cust/23207_1

name:HoT Internet
apn:webaut
protocol:0
dial:*99#

/jrd-resource/resource/profile/cust/23210

name:drei.at
apn:drei.at
protocol:0
dial:*99#

/jrd-resource/resource/profile/cust/23211

name:bob
apn:bob.at
protocol:3
dial:*99#
user:[email protected]
psw:ppp

/jrd-resource/resource/profile/cust/23211_bob

name:bob
apn:bob.at
protocol:3
dial:*99#
user:[email protected]
psw:ppp

/jrd-resource/resource/profile/cust/23212

name:Internet
apn:webapn.at
protocol:0
dial:*99#

/jrd-resource/resource/profile/cust/23212_Ge org:)

name:Internet
apn:webapn.at
protocol:0
dial:*99#

/jrd-resource/resource/profile/cust/23212_yesss!

name:Internet
apn:webapn.at
protocol:0
dial:*99#
Clone this wiki locally