NM-258: fix func comment

This commit is contained in:
abhishek9686
2026-02-24 01:08:33 +04:00
parent 5309aa70d4
commit 99c2d2d8d2
+2 -7
View File
@@ -133,13 +133,8 @@ func authenticate(response http.ResponseWriter, request *http.Request) {
response.Write(successJSONResponse)
}
// The middleware for most requests to the API
// They all pass through here first
// This will validate the JWT (or check for master token)
// This will also check against the authNetwork and make sure the node should be accessing that endpoint,
// even if it's technically ok
// This is kind of a poor man's RBAC. There's probably a better/smarter way.
// TODO: Consider better RBAC implementations
// AuthorizeHost - middleware that authenticates a host via JWT and ensures
// the host is only operating on its own resources (matched by hostid/nodeid path params).
func AuthorizeHost(
next http.Handler,
) http.HandlerFunc {