Skip to content
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

Bug in handling of texts with SMS.HTTPGateway.URL feature enabled #3

Open
zackorndorff opened this issue Mar 7, 2018 · 0 comments
Open

Comments

@zackorndorff
Copy link

Hi,

For some research I'm doing, I'm looking to get smqueue to call my script with each text I send from the test network. I skimmed through the source code and found the SMS.HTTPGateway.URL option and created an HTTP server to receive the requests.

I got it working, but I noticed that the incoming text message is not properly escaped, leading to a command injection vulnerability. With this configuration option enabled, and set to http://localhost:1337/%s/%s, I was able to reboot my machine running OpenBTS by sending a text message to a number that doesn't even exist.

I'm not reporting this as a security bug because it's an undocumented feature, and I know I wouldn't be amused if someone reported a security bug to me in a feature I didn't even document :) However, if someone deployed this configuration, it would lead to remote code execution (as the user running smqueue, which is usually root I think), so it should probably be fixed.

If you have trouble replicating this or have any questions, feel free to contact me.

Best,
Zack

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant