Shutdown or reboot computer/server by connect over RDP (Remote Desktop Protocol).
You have to create the certain user on computer/server and assign shutdown or reboot command on user logon.
• shutdown command - "shutdown /s /f /t 0"
• reboot command - "shutdown /r /f /t 0"
- If the operating system of Windows SERVER family is used on the server - dont forget to give the right of shutdown the system this user in group policy.