Differences
This shows you the differences between two versions of the page.
| Both sides previous revision Previous revision Next revision | Previous revision Next revisionBoth sides next revision | ||
| toh:etisalat:s3 [2023/01/12 16:00] – [Backup] csharper2005 | toh:etisalat:s3 [2023/10/16 20:12] – [Installation] csharper2005 | ||
|---|---|---|---|
| Line 5: | Line 5: | ||
| /* USE https:// | /* USE https:// | ||
| - | {{page> | ||
| OEM: Sercomm S3 | OEM: Sercomm S3 | ||
| Line 11: | Line 10: | ||
| Etisalat S3 is a wireless router based on the MT7621 platform with USB 3.0 port. | Etisalat S3 is a wireless router based on the MT7621 platform with USB 3.0 port. | ||
| - | {{media: | + | {{media:sercomm: |
| Line 40: | Line 39: | ||
| ===== Installation ===== | ===== Installation ===== | ||
| /* stable release */ | /* stable release */ | ||
| - | /* uncomment once stable release is available | + | |
| ---- datatable ---- | ---- datatable ---- | ||
| cols : Model, Versions, Supported Current Rel, Firmware OpenWrt Install URL_url, Firmware OpenWrt Upgrade URL_url, Firmware OEM Stock URL_url | cols : Model, Versions, Supported Current Rel, Firmware OpenWrt Install URL_url, Firmware OpenWrt Upgrade URL_url, Firmware OEM Stock URL_url | ||
| headers : Model, Version, Current Release, Firmware OpenWrt Install, Firmware OpenWrt Upgrade, Firmware OEM Stock | headers : Model, Version, Current Release, Firmware OpenWrt Install, Firmware OpenWrt Upgrade, Firmware OEM Stock | ||
| - | align : c,c,c | ||
| - | filter | ||
| - | filter | ||
| - | ---- | ||
| - | */ | ||
| - | |||
| - | |||
| - | /* snapshot */ | ||
| - | /* delete once stable release is available */ | ||
| - | ---- datatable ---- | ||
| - | cols : Model, Versions, Supported Current Rel, Firmware OpenWrt snapshot Install URL_url, Firmware OpenWrt snapshot Upgrade URL_url, Firmware OEM Stock URL_url | ||
| - | headers : Model, Version, Current Release, Firmware OpenWrt snapshot Install, Firmware OpenWrt snapshot Upgrade, Firmware OEM Stock | ||
| align : c,c,c | align : c,c,c | ||
| filter | filter | ||
| Line 71: | Line 58: | ||
| cfgtool.py -u configurationBackup.cfg | cfgtool.py -u configurationBackup.cfg | ||
| </ | </ | ||
| + | |||
| + | <hidden cfgtool.py> | ||
| + | <code bash> | ||
| + | """ | ||
| + | Copyright (c) 2022 r3d5ky | ||
| + | |||
| + | Permission is hereby granted, free of charge, to any person obtaining a copy | ||
| + | of this software and associated documentation files (the " | ||
| + | in the Software without restriction, | ||
| + | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | ||
| + | copies of the Software, and to permit persons to whom the Software is | ||
| + | furnished to do so, subject to the following conditions: | ||
| + | |||
| + | The above copyright notice and this permission notice shall be included in all | ||
| + | copies or substantial portions of the Software. | ||
| + | |||
| + | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, | ||
| + | EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF | ||
| + | MERCHANTABILITY, | ||
| + | IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, | ||
| + | DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR | ||
| + | OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE | ||
| + | OR OTHER DEALINGS IN THE SOFTWARE. | ||
| + | """ | ||
| + | |||
| + | import zlib | ||
| + | import sys | ||
| + | import argparse | ||
| + | |||
| + | def unpack(cfg_file, | ||
| + | with open(cfg_file, | ||
| + | infile = f.read() | ||
| + | |||
| + | unpacked = zlib.decompress(infile[4: | ||
| + | config = unpacked[unpacked.find(b' | ||
| + | userdata = unpacked[: | ||
| + | | ||
| + | if raw: | ||
| + | with open(cfg_file[: | ||
| + | f.write(unpacked) | ||
| + | |||
| + | with open(cfg_file[: | ||
| + | f.write(config) | ||
| + | with open(cfg_file[: | ||
| + | f.write(userdata) | ||
| + | |||
| + | |||
| + | def pack(xml_file, | ||
| + | with open(xml_file, | ||
| + | rawconfig = f.read() + b' | ||
| + | with open(xml_file[: | ||
| + | userdata = f.read() | ||
| + | endian = " | ||
| + | if endianness: | ||
| + | endian = " | ||
| + | crc = zlib.crc32(rawconfig).to_bytes(4, | ||
| + | config = userdata + rawconfig + crc | ||
| + | | ||
| + | with open(sys.argv[2][: | ||
| + | f.write(len(config).to_bytes(4, | ||
| + | |||
| + | |||
| + | def main(): | ||
| + | parser = argparse.ArgumentParser(description=" | ||
| + | group = parser.add_mutually_exclusive_group(required=True) | ||
| + | group.add_argument(" | ||
| + | group.add_argument(" | ||
| + | parser.add_argument(" | ||
| + | parser.add_argument(" | ||
| + | parser.add_argument(' | ||
| + | args = parser.parse_args() | ||
| + | | ||
| + | if args.unpack: | ||
| + | unpack(args.file, | ||
| + | elif args.pack: | ||
| + | pack(args.file, | ||
| + | |||
| + | print(" | ||
| + | |||
| + | |||
| + | if __name__ == ' | ||
| + | main() | ||
| + | </ | ||
| + | </ | ||
| + | |||
| 4. Open configurationBackup.xml and find the following line: | 4. Open configurationBackup.xml and find the following line: | ||
| Line 91: | Line 163: | ||
| 8. Login to the router web interface (SuperUser: | 8. Login to the router web interface (SuperUser: | ||
| - | 9. Navigate to Settings -> WAN -> Add static IP interface | + | 9. Navigate to Settings -> Access Control |
| - | 10. Navigate | + | 10. Connect |
| - | 11. Change IP of your client to 10.0.0.2/ | + | 11. Run in SSH shell: |
| - | + | ||
| - | 12. Connect to the router using SSH shell under SuperUser account | + | |
| - | + | ||
| - | 13. Run in SSH shell: | + | |
| <code bash> | <code bash> | ||
| sh | sh | ||
| </ | </ | ||
| - | 14. Make a mtd backup (optional, see related section) | + | 12. Make a mtd backup (optional, see related section) |
| - | 15. Change bootflag to Sercomm1 and reboot: | + | 13. Change bootflag to Sercomm1 and reboot: |
| <code bash> | <code bash> | ||
| printf 1 | dd bs=1 seek=7 count=1 of=/ | printf 1 | dd bs=1 seek=7 count=1 of=/ | ||
| Line 112: | Line 180: | ||
| </ | </ | ||
| - | 16. Login to the router web interface under admin account | + | 14. Login to the router web interface under admin account |
| - | 17. Remove dots from the OpenWrt factory image filename | + | 15. Remove dots from the OpenWrt factory image filename |
| - | 18. Update firmware via web using OpenWrt factory image | + | 16. Update firmware via web using OpenWrt factory image |
| ==== Backup ==== | ==== Backup ==== | ||
| Line 132: | Line 200: | ||
| </ | </ | ||
| - | ====== Return to Stock ====== | + | ==== Return to Stock ==== |
| 1. Change the bootflag to Sercomm1 in OpenWrt CLI and then reboot: | 1. Change the bootflag to Sercomm1 in OpenWrt CLI and then reboot: | ||
| <code bash> | <code bash> | ||
| printf 1 | dd bs=1 seek=7 count=1 of=/ | printf 1 | dd bs=1 seek=7 count=1 of=/ | ||
| </ | </ | ||
| - | 2. Optional: Update with any stock (Beeline) firmware if you want to overwrite OpenWrt in Slot 0 completely. | + | 2. Optional: Update with any stock (Etisalat S3) firmware if you want to overwrite OpenWrt in Slot 0 completely. |
| ==== Flash Layout ==== | ==== Flash Layout ==== | ||
| <WRAP BOX> | <WRAP BOX> | ||
| Line 195: | Line 263: | ||
| 2. Connect the router with a cable and run sercomm-recovery: | 2. Connect the router with a cable and run sercomm-recovery: | ||
| <code bash> | <code bash> | ||
| - | sudo ./ | + | sudo ./ |
| </ | </ | ||
| where //enp0s3// - network interface connected the router, // | where //enp0s3// - network interface connected the router, // | ||
| + | 3. Wait until the router is flashed and rebooted. | ||
| + | |||
| + | [[https:// | ||
| ===== Failsafe mode ===== | ===== Failsafe mode ===== | ||
| -> [[docs: | -> [[docs: | ||