PFS400 - Invalid or Unexpected Response from pfSense
Agent error code #206400#PFS400 indicates that the agent received a response from pfSense that it could not parse as a valid pfRest response. The call completed at the network level but the body was not in the expected format.
This error is distinct from the more specific failure codes because the failure mode is structural rather than semantic.
Common causes include:
- A pfRest version mismatch — the installed package is older or newer than what the agent expects
- A proxy or load balancer in front of pfSense returned its own HTML error page instead of the pfRest JSON body
- pfSense is mid-restart and serving an interim response
- The hostname in the Knocknoc backend points at a different web service entirely
Steps to Resolve
Reproduce the Call and Inspect the Body
- From the agent host, run
curl -v https://<pfsense-host>/api/v2/system/versionand inspect the response - Confirm the body is JSON. If it is HTML, you are hitting the wrong endpoint or a proxy is intercepting the request
Check the pfRest Version
- Log into pfSense and navigate to System > Package Manager > Installed Packages
- Confirm the pfSense-pkg-RESTAPI package is up to date
- If it is significantly out of date, upgrade it
Confirm No Proxy Is in the Way
- Confirm the pfSense URL in the Knocknoc backend points directly at the pfSense management interface
- If a proxy or load balancer sits between the agent and pfSense, confirm it passes through API responses without modification (no HTML error page substitution, no body rewriting)
For the full setup, see the pfSense setup guide.
Still Having Issues?
We can help you out, contact us at support@knocknoc.io.