Kernel for emulating TP-link ex820v

Hello I am a student researching router security in Iceland. My group has been tasked with emulating common routers for dynamic analysis. We have obtained a firmware image for a tp-link ex820v that seems to be running OpenWRT with this kernel: ARM64 OpenWrt Linux-5.4.211

I could use some help compiling a kernel that I can use to emulate this. I tried doing so myself but I was not able to find this exact device in the list of target profiles, so I'm wondering if I need the exact system or if I can get away with using something else?

you do.

you could try to contact TP-Link, and request the GPL sources from them.

searching the forum will show it's supportable, you can probably RAM boot an initramfs for a device using the same SoC.

1 Like

you could try to apply https://github.com/openwrt/openwrt/pull/13900 to the openwrt master, and build an image, but I have no idea what does, and doesn't work.
@Apache14 would know, I guess - TP-Link EX820v (MT7986) Switch Setup.

Official support for the dev(ce (s pending

You will not get representative kernel with buggy proprietary blobs from openwrt.org

Close aporoximations:

  • openwrt 21.02 SDK is likely to link against same libc, if it is not musl youll need to build static binaries.
  • 21.02 aarch64 in a vm or on raspberry
  • 21.02 x86_64
1 Like

I have started to pick up the MR and clean up the DTS and get all ports working (in the current PR one of the 2.5Gbps ports wont start, i have resolved this)