Skip to content

Add unauthenticated RCE on Shenzhen Aitemi M300 MT02 (CVE-2025-34152) #20455

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 7 commits into
base: master
Choose a base branch
from

Conversation

Chocapikk
Copy link
Contributor

Hello Metasploit Team,

This new module exploits CVE-2025-34152 in the Shenzhen Aitemi M300 MT02 by abusing the time_conf endpoint to run arbitrary commands as root without triggering a reboot or altering network settings. It delivers a reliable RCE vector while keeping the HTTP interface fully operational.

@Chocapikk Chocapikk force-pushed the aitemi_m300_time_rce branch from a1d46f6 to 4afb02c Compare August 7, 2025 19:52
@Chocapikk Chocapikk force-pushed the aitemi_m300_time_rce branch from 4afb02c to ff4ede9 Compare August 7, 2025 19:53
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there a way to get firmware from device to emulate it?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Chocapikk if you have a device with root perharps you could send us just a dummy rootfs? 👀, just bare minimum for us to chroot it?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey, I need to see how to setup a lab for this, as I have the physical device I didn't need to create a lab. I'll try thanks

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Chocapikk if you have a device with root perharps you could send us just a dummy rootfs? 👀, just bare minimum for us to chroot it?

files.zip

Copy link
Contributor

@dledda-r7 dledda-r7 Aug 14, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice! that would work great, just some side notes. the kernel appears to be an u-boot and generally is a PITA to get it running on qemu, most likely the best thing to do is to get a malta OpenWrt with kernel near to the one we have here (4.4) and just chroot the rootfs you shared.
I'll give it a shot

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice! that would work great, just some side notes. the kernel appears to be an u-boot and generally is a PITA to get it running on qemu, most likely the best thing to do is to get a malta OpenWrt with kernel near to the one we have here (4.4) and just chroot the rootfs you shared. I'll give it a shot

I was pretty close to getting it working. I used this kernel:

wget https://mirror-03.infra.openwrt.org/snapshots/targets/malta/be/openwrt-malta-be-vmlinux.elf

Then I converted the vendor rootfs.bin into ext4 and booted it with:

qemu-system-mips -M malta -cpu 24Kf -m 256M \
  -kernel openwrt-malta-be-vmlinux.elf \
  -drive if=ide,file=rootfs.ext4,format=raw \
  -append "console=ttyS0,115200 root=/dev/sda rootfstype=ext4 rootwait rw" \
  -netdev user,id=net0,hostfwd=tcp::8080-:80 \
  -device pcnet,netdev=net0 \
  -nographic

The issue is that the network interface doesn't come up, probably because I overwrite the drivers when replacing the rootfs, and I just haven't been able to fix that.

@jheysel-r7 jheysel-r7 self-assigned this Aug 13, 2025
Chocapikk and others added 4 commits August 14, 2025 16:01
Co-authored-by: msutovsky-r7 <martin_sutovsky@rapid7.com>
Co-authored-by: Spencer McIntyre <58950994+smcintyre-r7@users.noreply.github.com>
@jheysel-r7 jheysel-r7 removed their assignment Aug 15, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants