├── .gitignore ├── imgs ├── ostore_1.png ├── ostore_2.png ├── ostore_3.png └── ostore_4.png ├── test.sh ├── files ├── init.sud.rc ├── init.appscmd.rc ├── init.copy_adb_key.rc ├── copy_adb_key └── init.usb.configfs.rc ├── .github └── workflows │ └── release.yml ├── adbkey.pub ├── adbkey └── readme.md /.gitignore: -------------------------------------------------------------------------------- 1 | .artifacts -------------------------------------------------------------------------------- /imgs/ostore_1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/gogogoghost/nokia-2780-flip-jailbreak-tutorial/HEAD/imgs/ostore_1.png -------------------------------------------------------------------------------- /imgs/ostore_2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/gogogoghost/nokia-2780-flip-jailbreak-tutorial/HEAD/imgs/ostore_2.png -------------------------------------------------------------------------------- /imgs/ostore_3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/gogogoghost/nokia-2780-flip-jailbreak-tutorial/HEAD/imgs/ostore_3.png -------------------------------------------------------------------------------- /imgs/ostore_4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/gogogoghost/nokia-2780-flip-jailbreak-tutorial/HEAD/imgs/ostore_4.png -------------------------------------------------------------------------------- /test.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | set -e 4 | 5 | act --container-options "--privileged -v /dev:/dev" --artifact-server-path $PWD/.artifacts push 6 | -------------------------------------------------------------------------------- /files/init.sud.rc: -------------------------------------------------------------------------------- 1 | # su daemon 2 | service su_daemon /system/xbin/su --daemon 3 | group root 4 | seclabel u:r:su:s0 5 | user root 6 | 7 | on post-fs-data 8 | start su_daemon -------------------------------------------------------------------------------- /files/init.appscmd.rc: -------------------------------------------------------------------------------- 1 | # appscmd daemon 2 | service appscmd /system/xbin/appscmd daemon 3 | group root 4 | seclabel u:r:su:s0 5 | user root 6 | 7 | on post-fs-data 8 | start appscmd -------------------------------------------------------------------------------- /files/init.copy_adb_key.rc: -------------------------------------------------------------------------------- 1 | # copy adb key 2 | service adbkey /system/bin/copy_adb_key 3 | group root 4 | seclabel u:r:su:s0 5 | user root 6 | oneshot 7 | 8 | on post-fs-data 9 | start adbkey -------------------------------------------------------------------------------- /files/copy_adb_key: -------------------------------------------------------------------------------- 1 | #!/system/bin/sh 2 | 3 | mkdir -p /data/misc/adb 4 | chmod 0755 /data/misc/adb 5 | 6 | KEY_PATH="/data/misc/adb/adb_keys" 7 | if [ ! -f "$KEY_PATH" ]; then 8 | cp /system/adb/adb_keys $KEY_PATH 9 | chown 0:2000 $KEY_PATH 10 | chmod 0444 $KEY_PATH 11 | fi -------------------------------------------------------------------------------- /.github/workflows/release.yml: -------------------------------------------------------------------------------- 1 | name: Release 2 | run-name: Create release by ${{ github.actor }} 3 | on: 4 | push: 5 | tags: 6 | - '20*' 7 | jobs: 8 | release: 9 | runs-on: ubuntu-latest 10 | permissions: 11 | contents: write 12 | steps: 13 | - name: Checkout code 14 | uses: actions/checkout@v3 15 | 16 | - run: sudo bash build.sh 17 | 18 | # for test 19 | # - uses: actions/upload-artifact@v3 20 | # with: 21 | # name: output 22 | # path: output 23 | 24 | # for product 25 | - uses: ncipollo/release-action@v1 26 | with: 27 | artifacts: "output/*.xz" -------------------------------------------------------------------------------- /adbkey.pub: -------------------------------------------------------------------------------- 1 | QAAAALM1Wh+Ffnz/WeyURJajY+iBu+iePSu0Rb9lYriQ8CDJnrToUz0v030Ud/tSZjkWlugW1PBlhNmuhAWqRvsoRYGidHm9gwV5gUm2cO5se3BjbkUZV+lwSFiYjsQR0cacVySw3POKEKtjxXGOTmT3ur8B87SC6FVLrUuScHuXeZjUthWiuNsioHTPSPMvSC5eltugAM/hUb6NA2IvaY5sZg+m1qCVU38YMPzyoOtDqQdXnyO3YIWuY0MutOAt8YdMM8Fh5E1F7P676dNQM4wqQqU1yyfQ+5qZQiM1OtDjLzWXYkNf9ybkAktxnnUXIpmaNCgIrfFNV4DE5aDozEm1CgurPgSXNz12B2FcPowRiBwiSzyqYswmDBleYVnddNovE2CocSiORBW3ED0NJcEYLAImaIn4GA5lIs/32dYQaPDzKM9Gb6UUpJ3qChVr5YkYxiuc7JK3MbUDq2I4cQjjiQrQfJqUyux4pjYCNFL9ZlpnXxxi/acNy4XPJngdUbnRFAZo3Yd3CNlvPFAA4unBxG0LVoB6Rm9PvAPpQQYbni9mCZpce9CE76ZHW/og0wuyVGnd3c7BUIaxKUxnexZwdHqujaSIloJ838+ljNSYUHvz8t8GQPw2eBfmhlXFGA2iJgHnAykkykkdkQ7FN2nG0wfHHwSFL48FLFMPFYUCQp6BvSu6CgEAAQA= jax@archlinux -------------------------------------------------------------------------------- /adbkey: -------------------------------------------------------------------------------- 1 | -----BEGIN PRIVATE KEY----- 2 | MIIEvgIBADANBgkqhkiG9w0BAQEFAASCBKgwggSkAgEAAoIBAQCXBD6rCwq1Sczo 3 | oOXEgFdN8a0IKDSamSIXdZ5xSwLkJvdfQ2KXNS/j0Do1I0KZmvvQJ8s1pUIqjDNQ 4 | 0+m7/uxFTeRhwTNMh/Et4LQuQ2OuhWC3I59XB6lD66Dy/DAYf1OVoNamD2Zsjmkv 5 | YgONvlHhzwCg25ZeLkgv80jPdKAi27iiFbbUmHmXe3CSS61LVeiCtPMBv7r3ZE6O 6 | ccVjqxCK89ywJFecxtERxI6YWEhw6VcZRW5jcHts7nC2SYF5BYO9eXSigUUo+0aq 7 | BYSu2YRl8NQW6JYWOWZS+3cUfdMvPVPotJ7JIPCQuGJlv0W0Kz2e6LuB6GOjlkSU 8 | 7Fn/fH6FAgMBAAECggEAR39m/Cv6IeKS9QBYSDRLIUfumBIQ9bDShzDUlubgs4wP 9 | SjbpEpXH2p/XLxlGitrppZ9xgjB/pw1Brl7mJm+HBTjfi7igxPcHpKTiKZUWOKZF 10 | J+/hnJ6v8Mw6I1BqpO6DcC/58B0SbQrvmdNZw137/mC293F/O4/F9Y3FRxL8TgPm 11 | R1WZ4kMjxBd35lRpgye49mnY3/e4geN6mFRT+hg5TXHJDY0yaSNJ3HEMxtPLkWD7 12 | WxXv+81B9t3dumRefpC3nQSCWO2KMfcYHBFSZ51xwSsfCmF7FILjFi/0Pzo0OyJs 13 | e43+E8HZPw+Xbwumzbh1Kpm/FW38SeoCBra7DUtj8QKBgQDSV2w0aq0rbNNyT5P7 14 | mO2eKh9vYHBvGUeHAptghvmoidtiH66Ea6MxOpV4OjEcOgR5rwdry2ZN2TW9iLLj 15 | 7qhbGP9YeyFiYQwriB6ih5QDPNSPW5hmJkPgKg2M2jFDjbjztVkeoAIWmuUXrSxV 16 | FWYlwBD3QlPwzg2EK8mlHlBIJwKBgQC3zCotCZwMuqb4XxBn8KPK+NIc0ADYelAp 17 | CXyXgDft4abdHXYOaX5KVVx9Gv0CQjWVNIDp7T3pSz/ff4yTSRdwil78uT8OP9I+ 18 | pmUY7gN0kKo11c9VaWRRDNG19WcZeJrra++rDKPXzr5ZBbVQLxh/5ueHInaATMk9 19 | J2vkNHNjcwKBgQCa6c4EcMinIdg86UT42PGwOh+6vJEyEbEvSwk6N05qBVXw15qF 20 | ZmzjVd09lcYTntsq73CMwFnRXfcJZ0MxQdT2etucw9qbhRQcf3zogOfO1p9KEdCU 21 | 8vusfexK32vG7/rWaqp/NqMzGNM+88ihxUfc567XHB+MS4WC4Wj6VfAUowKBgAuQ 22 | GZspvpqCZ5y6hlKzrepICxfq8hKsZzydryvs0hfyGUhR4Sp48owEoMPyHba1qZ9Q 23 | ZUfSOBHkPQl3gcWGVKYs3lrx4Iip9TUhzLxrxOXhcAPhBqEt9zSuJMdYv/q3Pq/O 24 | 444URn5+MDVziXuY6uapBSnYPjJGImbpgv0hW50HAoGBAKKRjgau6HU/MgBYKton 25 | b0D9ddDZdV3CtFRnKgWU831dLg7OhJAfEsU53XS+NocTHJdJKSaoWQL8GgdcFb2Y 26 | TAx0IZ+lZ6tojrouxzPVI24Zg858uwZ0ok+OhU17B1kdaWEpNZU53PXExAulzstM 27 | gLL3kgL8D442l+B/dgenG5QA 28 | -----END PRIVATE KEY----- 29 | -------------------------------------------------------------------------------- /readme.md: -------------------------------------------------------------------------------- 1 | ## Nokia 2780 flip jailbreak tutorial 2 | 3 | This tutorial can lead you to jailbreak your nokia 2780 flip. Include sideload apps and root. 4 | 5 | ### Screenshot 6 | 7 | Image from this repository contains [ostore](https://github.com/gogogoghost/ostore) to sideload apps. If you uninstalled it. You can do factory reset (format data) or using [appscmd](#sideload-apps-via-cli) to reinstall. 8 | 9 | ![1](imgs/ostore_1.png) 10 | ![2](imgs/ostore_2.png) 11 | ![3](imgs/ostore_3.png) 12 | ![4](imgs/ostore_4.png) 13 | 14 | 15 | ### Prepare 16 | 17 | [recovery images](https://github.com/gogogoghost/nokia-2780-flip-jailbreak-tutorial/releases/tag/weeknd-toolbox) (built from [weeknd-toolbox](https://git.abscue.de/affe_null/weeknd-toolbox/)) 18 | 19 | [boot.img](https://github.com/gogogoghost/nokia-2780-flip-jailbreak-tutorial/releases/tag/patched-files) 20 | Patched boot.img has been replaced the kernel cmdline from **androidboot.selinux=enforcing** to **androidboot.selinux=permissive** 21 | 22 | [system.img](https://github.com/gogogoghost/nokia-2780-flip-jailbreak-tutorial/releases/latest) 23 | 24 | ### Flash them in fastboot mode 25 | 26 | Reboot the device and press volume down while booting to enter fastboot. 27 | Then using fastboot cli to flash them. 28 | 29 | ```bash 30 | # grant permission 31 | fastboot oem sudo 32 | 33 | # flash recovery 34 | fastboot flash avb_custom_key pkmd.bin 35 | fastboot flash vbmeta vbmeta.img 36 | fastboot flash recovery lk2nd.img 37 | 38 | # flash boot.img 39 | fastboot flash boot boot.img 40 | 41 | # flash system.img 42 | fastboot flash system system.img 43 | 44 | # format data (first time) 45 | fastboot format userdata 46 | fastboot format cache 47 | 48 | # reboot 49 | fastboot reboot 50 | ``` 51 | 52 | Every upgrade you just need to flash the new system.img. 53 | 54 | ### Adb 55 | 56 | Enable "Settings -> Storage -> USB storage". Then your PC can discovery a adb device. 57 | 58 | Due to the adbd cannot exchange key. This image contains a pre generated key at **/data/misc/adb/adb_keys**. 59 | 60 | You need to use the adb key in this repository to connect to it. 61 | 62 | ```bash 63 | export export ADB_VENDOR_KEYS=$(REPOSITORY_DIR)/adbkey 64 | adb shell 65 | ``` 66 | 67 | Or you can replace the key by yourself. 68 | 69 | System will restore the adb key if **/data/misc/adb/adb_keys** not exist during boot. 70 | 71 | ### Sideload apps via cli 72 | 73 | Image contains [appscmd](https://github.com/gogogoghost/appscmd) to sideload apps. 74 | 75 | ```bash 76 | adb shell 77 | 78 | # install a app 79 | adb push application.zip /data/local/tmp/ 80 | appscmd install /data/local/tmp/application.zip 81 | 82 | # install a pwa 83 | appscmd install-pwa https://xxx.com/manifest.webmanifest 84 | 85 | # list apps 86 | appscmd list 87 | ``` 88 | 89 | ### How to enter recovery 90 | 91 | Reboot device and press volume up while booting. You will see the warning screen. Press power key twice can skip it. Or you need to wait for some seconds. 92 | 93 | After the warning screen disappear. Press volume up again until the device enter weeknd toolbox. 94 | -------------------------------------------------------------------------------- /files/init.usb.configfs.rc: -------------------------------------------------------------------------------- 1 | on property:sys.usb.config=none && property:sys.usb.configfs=1 2 | write /config/usb_gadget/g1/UDC "none" 3 | stop adbd 4 | setprop sys.usb.ffs.ready 0 5 | write /config/usb_gadget/g1/bDeviceClass 0 6 | write /config/usb_gadget/g1/bDeviceSubClass 0 7 | write /config/usb_gadget/g1/bDeviceProtocol 0 8 | rm /config/usb_gadget/g1/configs/b.1/f1 9 | rm /config/usb_gadget/g1/configs/b.1/f2 10 | rm /config/usb_gadget/g1/configs/b.1/f3 11 | rmdir /config/usb_gadget/g1/functions/rndis.gs4 12 | setprop sys.usb.state ${sys.usb.config} 13 | 14 | on property:init.svc.adbd=stopped 15 | setprop sys.usb.ffs.ready 0 16 | 17 | on property:sys.usb.config=adb && property:sys.usb.configfs=1 18 | start adbd 19 | 20 | on property:sys.usb.ffs.ready=1 && property:sys.usb.config=adb && property:sys.usb.configfs=1 21 | write /config/usb_gadget/g1/configs/b.1/strings/0x409/configuration "adb" 22 | symlink /config/usb_gadget/g1/functions/ffs.adb /config/usb_gadget/g1/configs/b.1/f1 23 | write /config/usb_gadget/g1/UDC ${sys.usb.controller} 24 | setprop sys.usb.state ${sys.usb.config} 25 | 26 | on property:sys.usb.config=mtp && property:sys.usb.configfs=1 27 | start adbd 28 | 29 | on property:sys.usb.ffs.ready=1 && property:sys.usb.config=mtp && property:sys.usb.configfs=1 30 | write /config/usb_gadget/g1/configs/b.1/strings/0x409/configuration "mtp_adb" 31 | symlink /config/usb_gadget/g1/functions/mtp.gs0 /config/usb_gadget/g1/configs/b.1/f1 32 | symlink /config/usb_gadget/g1/functions/ffs.adb /config/usb_gadget/g1/configs/b.1/f2 33 | write /config/usb_gadget/g1/UDC ${sys.usb.controller} 34 | setprop sys.usb.state ${sys.usb.config} 35 | 36 | #on property:sys.usb.config=mtp && property:sys.usb.configfs=1 37 | # write /config/usb_gadget/g1/configs/b.1/strings/0x409/configuration "mtp" 38 | # symlink /config/usb_gadget/g1/functions/mtp.gs0 /config/usb_gadget/g1/configs/b.1/f1 39 | # write /config/usb_gadget/g1/UDC ${sys.usb.controller} 40 | # setprop sys.usb.state ${sys.usb.config} 41 | 42 | on property:sys.usb.config=mtp,adb && property:sys.usb.configfs=1 43 | start adbd 44 | 45 | on property:sys.usb.ffs.ready=1 && property:sys.usb.config=mtp,adb && property:sys.usb.configfs=1 46 | write /config/usb_gadget/g1/configs/b.1/strings/0x409/configuration "mtp_adb" 47 | symlink /config/usb_gadget/g1/functions/mtp.gs0 /config/usb_gadget/g1/configs/b.1/f1 48 | symlink /config/usb_gadget/g1/functions/ffs.adb /config/usb_gadget/g1/configs/b.1/f2 49 | write /config/usb_gadget/g1/UDC ${sys.usb.controller} 50 | setprop sys.usb.state ${sys.usb.config} 51 | 52 | on property:sys.usb.config=ptp && property:sys.usb.configfs=1 53 | write /config/usb_gadget/g1/configs/b.1/strings/0x409/configuration "ptp" 54 | symlink /config/usb_gadget/g1/functions/ptp.gs1 /config/usb_gadget/g1/configs/b.1/f1 55 | write /config/usb_gadget/g1/UDC ${sys.usb.controller} 56 | setprop sys.usb.state ${sys.usb.config} 57 | 58 | on property:sys.usb.config=ptp,adb && property:sys.usb.configfs=1 59 | start adbd 60 | 61 | on property:sys.usb.ffs.ready=1 && property:sys.usb.config=ptp,adb && property:sys.usb.configfs=1 62 | write /config/usb_gadget/g1/configs/b.1/strings/0x409/configuration "ptp_adb" 63 | symlink /config/usb_gadget/g1/functions/ptp.gs1 /config/usb_gadget/g1/configs/b.1/f1 64 | symlink /config/usb_gadget/g1/functions/ffs.adb /config/usb_gadget/g1/configs/b.1/f2 65 | write /config/usb_gadget/g1/UDC ${sys.usb.controller} 66 | setprop sys.usb.state ${sys.usb.config} 67 | 68 | on property:sys.usb.config=accessory && property:sys.usb.configfs=1 69 | write /config/usb_gadget/g1/configs/b.1/strings/0x409/configuration "accessory" 70 | symlink /config/usb_gadget/g1/functions/accessory.gs2 /config/usb_gadget/g1/configs/b.1/f1 71 | write /config/usb_gadget/g1/UDC ${sys.usb.controller} 72 | setprop sys.usb.state ${sys.usb.config} 73 | 74 | on property:sys.usb.config=accessory,adb && property:sys.usb.configfs=1 75 | start adbd 76 | 77 | on property:sys.usb.ffs.ready=1 && property:sys.usb.config=accessory,adb && property:sys.usb.configfs=1 78 | write /config/usb_gadget/g1/configs/b.1/strings/0x409/configuration "accessory_adb" 79 | symlink /config/usb_gadget/g1/functions/accessory.gs2 /config/usb_gadget/g1/configs/b.1/f1 80 | symlink /config/usb_gadget/g1/functions/ffs.adb /config/usb_gadget/g1/configs/b.1/f2 81 | write /config/usb_gadget/g1/UDC ${sys.usb.controller} 82 | setprop sys.usb.state ${sys.usb.config} 83 | 84 | on property:sys.usb.config=audio_source && property:sys.usb.configfs=1 85 | write /config/usb_gadget/g1/configs/b.1/strings/0x409/configuration "audiosource" 86 | symlink /config/usb_gadget/g1/functions/audio_source.gs3 /config/usb_gadget/g1/configs/b.1/f1 87 | write /config/usb_gadget/g1/UDC ${sys.usb.controller} 88 | setprop sys.usb.state ${sys.usb.config} 89 | 90 | on property:sys.usb.config=audio_source,adb && property:sys.usb.configfs=1 91 | start adbd 92 | 93 | on property:sys.usb.ffs.ready=1 && property:sys.usb.config=audio_source,adb && property:sys.usb.configfs=1 94 | write /config/usb_gadget/g1/configs/b.1/strings/0x409/configuration "audiosource_adb" 95 | symlink /config/usb_gadget/g1/functions/audio_source.gs3 /config/usb_gadget/g1/configs/b.1/f1 96 | symlink /config/usb_gadget/g1/functions/ffs.adb /config/usb_gadget/g1/configs/b.1/f2 97 | write /config/usb_gadget/g1/UDC ${sys.usb.controller} 98 | setprop sys.usb.state ${sys.usb.config} 99 | 100 | on property:sys.usb.config=accessory,audio_source && property:sys.usb.configfs=1 101 | write /config/usb_gadget/g1/configs/b.1/strings/0x409/configuration "accessory_audiosource" 102 | symlink /config/usb_gadget/g1/functions/accessory.gs2 /config/usb_gadget/g1/configs/b.1/f1 103 | symlink /config/usb_gadget/g1/functions/audio_source.gs3 /config/usb_gadget/g1/configs/b.1/f2 104 | write /config/usb_gadget/g1/UDC ${sys.usb.controller} 105 | setprop sys.usb.state ${sys.usb.config} 106 | 107 | on property:sys.usb.config=accessory,audio_source,adb && property:sys.usb.configfs=1 108 | start adbd 109 | 110 | on property:sys.usb.ffs.ready=1 && property:sys.usb.config=accessory,audio_source,adb && property:sys.usb.configfs=1 111 | write /config/usb_gadget/g1/configs/b.1/strings/0x409/configuration "accessory_audiosource_adb" 112 | symlink /config/usb_gadget/g1/functions/accessory.gs2 /config/usb_gadget/g1/configs/b.1/f1 113 | symlink /config/usb_gadget/g1/functions/audio_source.gs3 /config/usb_gadget/g1/configs/b.1/f2 114 | symlink /config/usb_gadget/g1/functions/ffs.adb /config/usb_gadget/g1/configs/b.1/f3 115 | write /config/usb_gadget/g1/UDC ${sys.usb.controller} 116 | setprop sys.usb.state ${sys.usb.config} 117 | 118 | on property:sys.usb.config=midi && property:sys.usb.configfs=1 119 | write /config/usb_gadget/g1/configs/b.1/strings/0x409/configuration "midi" 120 | symlink /config/usb_gadget/g1/functions/midi.gs5 /config/usb_gadget/g1/configs/b.1/f1 121 | write /config/usb_gadget/g1/UDC ${sys.usb.controller} 122 | setprop sys.usb.state ${sys.usb.config} 123 | 124 | on property:sys.usb.config=midi,adb && property:sys.usb.configfs=1 125 | start adbd 126 | 127 | on property:sys.usb.ffs.ready=1 && property:sys.usb.config=midi,adb && property:sys.usb.configfs=1 128 | write /config/usb_gadget/g1/configs/b.1/strings/0x409/configuration "midi_adb" 129 | symlink /config/usb_gadget/g1/functions/midi.gs5 /config/usb_gadget/g1/configs/b.1/f1 130 | symlink /config/usb_gadget/g1/functions/ffs.adb /config/usb_gadget/g1/configs/b.1/f2 131 | write /config/usb_gadget/g1/UDC ${sys.usb.controller} 132 | setprop sys.usb.state ${sys.usb.config} 133 | 134 | on property:sys.usb.config=rndis && property:sys.usb.configfs=1 135 | mkdir /config/usb_gadget/g1/functions/rndis.gs4 136 | write /config/usb_gadget/g1/configs/b.1/strings/0x409/configuration "rndis" 137 | symlink /config/usb_gadget/g1/functions/rndis.gs4 /config/usb_gadget/g1/configs/b.1/f1 138 | write /config/usb_gadget/g1/UDC ${sys.usb.controller} 139 | setprop sys.usb.state ${sys.usb.config} 140 | 141 | on property:sys.usb.config=rndis,adb && property:sys.usb.configfs=1 142 | start adbd 143 | 144 | on property:sys.usb.ffs.ready=1 && property:sys.usb.config=rndis,adb && property:sys.usb.configfs=1 145 | mkdir /config/usb_gadget/g1/functions/rndis.gs4 146 | write /config/usb_gadget/g1/configs/b.1/strings/0x409/configuration "rndis_adb" 147 | symlink /config/usb_gadget/g1/functions/rndis.gs4 /config/usb_gadget/g1/configs/b.1/f1 148 | symlink /config/usb_gadget/g1/functions/ffs.adb /config/usb_gadget/g1/configs/b.1/f2 149 | write /config/usb_gadget/g1/UDC ${sys.usb.controller} 150 | setprop sys.usb.state ${sys.usb.config} --------------------------------------------------------------------------------