Skip to content

Instantly share code, notes, and snippets.

@cmbaughman
Created June 8, 2022 23:49
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save cmbaughman/7d68e65d4f895bd25893a796e1113122 to your computer and use it in GitHub Desktop.
Save cmbaughman/7d68e65d4f895bd25893a796e1113122 to your computer and use it in GitHub Desktop.
Fun with Roku

Fun stuff with Roku

Enumerate Roku devices

sudo nmap -sV -O -n 192.168.X.X/24

Identify the device and other stuff using netcat on the SSDP multicast address, port 1900.

nc -u 239.255.255.250 1900 < Roku_Enum.txt

If the Roku accepts ECP (External Control Protocol) we can use the REST API to the Roku's built in webserver.

The commands are listed here: https://developer.roku.com/docs/developer-program/debugging/external-control-api.md I highly recommend the documentation there for "deep linking" and other stuff to make Roku more fun.

Example viewing everything you could want to know about the device:

http://192.168.X.X:8060/query/device-info

You can also issue commands like a remote:

# Supported keys:
# Home
# Rev
# Fwd
# Play
# Select
# Left
# Right
# Down
# Up
# Back
# InstantReplay
# Info
# Backspace
# Search
# Enter

curl -d '' http://192.168.x.x:8060/keypress/select

Make Roku search for a movie:

curl -d '' http://192.168.1.76:8060/search/browse?keyword=Some%20Crap
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment