Third assignment: Wake on LAN server

The third assignment is a server to wake up computers through the network. The server allows clients to schedule a wake-up operation into the future. This third assignment only uses UDP protocol.

For managing the list of pending wake-up requests a hash table (or similar) can make your job easier.

Update: I have added a sample server on the campus network. You can reach it with command nc -u msanchez.upv.es 2323 and it works as the exercise requests. Please note you can only interact with it from inside the campus network, otherwise you'll be blocked by the campus firewall. If you want to use it from your home, please create a VPN connection to the campus network.

You can receive the response by specifying your own IP address and running this other command: nc -ulp 7 on your computer (for this command you'll need administrative rights). Please remember the message is scheduled to be transmitted once the time has passed. If this command is not running before datagram is transmitted then datagram will be lost (it is not queued anywhere).

Update: One small detail is that nc command will add an end-of-line marker (char 0x0a in OSX and Linux) to the text you just typed at the terminal when you press enter key.

Update II (March 9th): An unscheduled power outage left the sample server out of service for a few days. Now it is back online.

No comments: