-
Notifications
You must be signed in to change notification settings - Fork 60
Description
I am struggling to get the function_call for WakeOnLan to work with FauxAPI.
I'm able to use the exec_command and wake that way, but that gives the API user too much access that I do not want. This works and sends a WOL packet fine:
fauxapi --host pfsense --apikey **** --apisecret ***** function_call "{\"function\": \"exec_command\", \"args\": \"wake igb1.20 78:5d:c8:ee:ff:aa\"}"
This below function_call using the WakeOnLan function does not work, though everything appears that it should work.
fauxapi --host pfsense --apikey **** --apisecret ***** function_call "{\"function\": \"WakeOnLan\", \"args\": [\"192.168.20.255\", \"78:5d:c8:ee:ff:aa\"]}"
The FauxAPI logs even show that it processed the command and sends a magic packet, but I don't see it actually sending a magic packet.
Jul 26 10:02:51 pfSense php-fpm[61319]: {"INFO":"20200726Z100251 :: fauxapi\\v1\\fauxApi::__call","DATA":{"user_action":"function_call","callid":"5f1d8d0bc9ba9","client_ip":"192.168.30.203"},"source":"fauxapi"}
Jul 26 10:02:51 pfSense php-fpm[61319]: /fauxapi/v1/index.php: Magic Packet sent () to (192.168.20.255) MAC=78:5d:c8:ee:ff:aa
Any ideas?