Skip to content

Commit 9515128

Browse files
committed
Respond 401 not 404 when bad request token
1 parent 9ca5f97 commit 9515128

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,10 @@ This file is a running track of new features and fixes to each version of the pa
33

44
This project follows [Semantic Versioning](http://semver.org) guidelines.
55

6+
## v0.6.4 (Courageous Carniadactylus)
7+
### Changed
8+
* Panel API for Daemon now responds with a `HTTP/401 Unauthorized` error when unable to locate a node with a given authentication token, rather than a `HTTP/404 Not Found` response.
9+
610
## v0.6.3 (Courageous Carniadactylus)
711
### Fixed
812
* **[Security]** — Addresses an oversight in how the terminal rendered information sent from the server feed which allowed a malicious user to execute arbitrary commands on the game-server process itself by using a specifically crafted in-game command.

app/Http/Middleware/DaemonAuthenticate.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ public function handle($request, Closure $next)
7676

7777
$node = Node::where('daemonSecret', $request->header('X-Access-Node'))->first();
7878
if (! $node) {
79-
return abort(404);
79+
return abort(401);
8080
}
8181

8282
return $next($request);

0 commit comments

Comments
 (0)