Skip to content

Commit

Permalink
fix addon
Browse files Browse the repository at this point in the history
  • Loading branch information
volkmarnissen committed Oct 26, 2024
1 parent 777dfe1 commit 49be0d9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/httpServerBase.ts
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,7 @@ export class HttpServerBase {
let config = Config.getConfiguration()
if (config.hassiotoken) {
let address = (req.socket.address() as AddressInfo).address
if (!address || ['172.30.33.1','172.30.32.1', '127.0.0.1'].includes(address)) {
if (!address || !['172.30.33.1','172.30.32.1', '127.0.0.1'].includes(address)) {
log.log(LogLevelEnum.warn, 'Denied: IP Address is not allowed ' + address)
this.returnResult(req, res, HttpErrorsEnum.ErrForbidden, 'Unauthorized (See server log)')
return
Expand Down

0 comments on commit 49be0d9

Please sign in to comment.