aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorcel <cel@lOUVT+Phkvai9a/cCS/RKo+S9hnPAQdVixms/7ldpPA=.ed25519>2020-03-28 15:58:05 -0400
committercel <cel@lOUVT+Phkvai9a/cCS/RKo+S9hnPAQdVixms/7ldpPA=.ed25519>2020-05-09 11:09:27 -0400
commit0e96112c494abb83e8cd9696a4ca08a09d4fb2ef (patch)
treeef1a7f598c2027dd279a482d5fe10f8e99154653
parent912a387ae7c8732d21026c16c80eb220526dd6fd (diff)
downloadpatchfoo-0e96112c494abb83e8cd9696a4ca08a09d4fb2ef.tar.gz
patchfoo-0e96112c494abb83e8cd9696a4ca08a09d4fb2ef.zip
Use 401 only for Basic Auth
-rw-r--r--lib/serve.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/serve.js b/lib/serve.js
index 71426c3..46b78e7 100644
--- a/lib/serve.js
+++ b/lib/serve.js
@@ -107,7 +107,7 @@ Serve.prototype.go = function () {
if (allowAddresses) {
var ip = this.req.socket.remoteAddress
if (allowAddresses.indexOf(ip) === -1) {
- this.res.writeHead(401)
+ this.res.writeHead(403)
return this.res.end('Not authorized')
}
}