[release] v0.10.0-unstable27

This commit is contained in:
Yann Stepienik 2023-10-06 17:33:05 +01:00
parent 443f584cb3
commit 2220b03847
2 changed files with 2 additions and 2 deletions

View file

@ -1,6 +1,6 @@
{
"name": "cosmos-server",
"version": "0.10.0-unstable26",
"version": "0.10.0-unstable27",
"description": "",
"main": "test-server.js",
"bugs": {

View file

@ -305,7 +305,7 @@ func Restrictions(RestrictToConstellation bool, WhitelistInboundIPs []string) fu
isWhitelistPassing := !isUsingWhiteList || isInWhitelist
// check if the request is coming from the constellation IP range 192.168.201.0/24
if (!isInConstellationPassing || !isWhitelistPassing) {
if (!isInConstellationPassing && !isWhitelistPassing) {
Log("Request from " + ip + " is blocked because of restrictions isInConstellationPassing: " + fmt.Sprintf("%v", isInConstellationPassing) + " and isWhitelistPassing: " + fmt.Sprintf("%v", isWhitelistPassing))
http.Error(w, "Access denied", http.StatusForbidden)
return