New Error: InvalidPayload

Posted on
Wed Jan 13, 2021 9:25 am
MartinG offline
Posts: 116
Joined: Aug 19, 2016

New Error: InvalidPayload

Hi Karl,

I'm seeing the following every minute or two:

Code: Select all
   uniFiAP Error                   UNIFI executeCMDOnController  login cmd:/usr/bin/curl --insecure -c /tmp/unifiCookie -H "Content-Type: application/json" --data '{"username": "", "strict": false, "password": ""}' 'https://192.168.1.109:8443/api/login'
gives  error: {"meta":{"rc":"error","msg":"api.err.InvalidPayload"},"data":[]}
   % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed

  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
100   113  100    64  100    49   1015    777 --:--:-- --:--:-- --:--:--  1793


I notice that my credentials are missing from the login command, but they are very definitely entered (and correct) in the plugin config.

Not sure when this started I'm afarid.

Thanks!

Martin

Posted on
Fri Jan 15, 2021 7:28 am
kw123 offline
User avatar
Posts: 8360
Joined: May 12, 2013
Location: Dallas, TX

Re: New Error: InvalidPayload

Will check in the next days
Karl


Sent from my iPhone using Tapatalk

Posted on
Tue Jan 19, 2021 11:53 am
MartinG offline
Posts: 116
Joined: Aug 19, 2016

Re: New Error: InvalidPayload

Hi Karl,

I dug into this a little further, and printed the config params to the logfile.

In the Controller section, I found this, which suggests the UserID and PassWd were not being captured correctly. They were (present and correct!) in the config dialog, and also visible (also correctly) in other sections of the printed parameters.

Code: Select all
17:28:15                          -====== CONTROLLER/UDM WEB ACCESS , set parameters and reporting
17:28:15                          -  curl data={WEB-UserID:..,WEB-PassWd:..} https://controllerIP: ..--------------
17:28:15                          -Mode: off, ON, UDM, reports only        ON
17:28:15                          -WEB-UserID                             
17:28:15                          -WEB-PassWd                             
17:28:15                          -Controller Type (UDM,..,std)            std
17:28:15                          -use strict:true for web login           F
17:28:15                          -Controller port#                        8443
17:28:15                          -Controller site Name                    default
17:28:15                          -Controller API WebPage                  /api/s/
17:28:15                          -Controller API login WebPage            /api/login
17:28:15                          -get blocked client info from Cntr every 180[sec]
17:28:15                          -get lastseen info from Cntr every       999999999[sec]
17:28:15                          -


Then I tried saving with different credentials, printing the parameters again, and this time the creds made it into the logfile.

So I changed them back to the correct values, saved the config, printed the params (creds now correctly reflected in logfile) and magically the errors are gone.

:D

Page 1 of 1

Who is online

Users browsing this forum: No registered users and 3 guests

cron