Server logs master key error even if it has been not used #8829
Labels
block:major
Needs to be resolved before next major release; remove label afterwards
state:breaking
Breaking change requires major version increment and `BREAKING CHANGE` commit message
type:bug
Impaired feature or lacking behavior that is likely assumed
New Issue Checklist
Issue Description
If
masterKeyIps
is defined and I try to access data in a public class via REST API and if the request hasX-Parse-Master-Key
header then the server returns the needed response but also logs this errorerror: Request using master key rejected as the request IP address '::1' is not set in Parse Server option 'masterKeyIps'.
Request (Has Master-Key header) ->(Tries to access a public class) -> Server (Gives response but logs error for IP is not allowed for masterKey)
Request (Has Master-Key header) ->(Tries to access a masterKey only class) -> Server (denies and logs error for IP is not allowed for masterKey)
Steps to reproduce
Set your
masterKeyIps
, add X-Parse-Master-Key to your header in the request and try to access a public classActual Outcome
error: Request using master key rejected as the request IP address '::1' is not set in Parse Server option 'masterKeyIps'.
Expected Outcome
Server should not log that since I was not trying to use Master Key for my operation cause it was a access request to a public class data
Environment
"dependencies": {
"axios": "1.6.0",
"dotenv": "^16.3.1",
"express": "4.18.2",
"ip-range-check": "^0.2.0",
"parse": "4.1.0",
"parse-server": "6.3.1"
}
Server
6.3.1
Windows 10
Localhost
Database
MongoDB
7.0.3
local
Client
REST API
None
Logs
error: Request using master key rejected as the request IP address '::1' is not set in Parse Server option 'masterKeyIps'.
The text was updated successfully, but these errors were encountered: