Repository Analysis

gravitl/netmaker

Netmaker makes networks with WireGuard. Netmaker automates fast, secure, and distributed virtual networks.

0.9 Likely human-written View on GitHub
0.9
Adjusted Score
0.9
Raw Score
100%
Time Factor
2026-05-30
Last Push
11,593
Stars
Go
Language
73,609
Lines of Code
386
Files
66
Pattern Hits
2026-05-31
Scan Date

Score History

Severity Breakdown

CRITICAL 0HIGH 0MEDIUM 1LOW 65

Pattern Findings

66 matches across 2 categories. Click a row to expand file-level details.

Over-Commented Block65 hits · 65 pts
SeverityFileLineSnippet
LOWservercfg/serverconf.go821// This ensures migrations, IDP sync, and other singleton operations only run on one pod.
LOWdatabase/database.go61 // PENDING_USERS_TABLE_NAME - table name for pending users
LOWpro/logic/acls.go641}
LOWpro/logic/status.go121 b. if getting failedover and still no connection to any of the peers - then show error
LOWpro/controllers/users.go2161 logic.ReturnSuccessResponse(w, r, "idp sync test successful")
LOWpro/controllers/jit.go41// @Param network query string true "Network ID"
LOWpro/controllers/jit.go501 if err != nil {
LOWpro/controllers/auto_relay.go181 mq.PublishPeerUpdate(false)
LOWpro/controllers/events.go21// @Summary List network activity
LOWpro/controllers/events.go81// @Summary List user activity
LOWpro/controllers/flows.go61 EndTs time.Time `ch:"end_ts" json:"end_ts"`
LOWpro/controllers/posture_check.go41 logic.ReturnSuccessResponseWithJson(w, r, schema.PostureCheckAttrValues, "fetched posture checks")
LOWpro/controllers/posture_check.go161 r,
LOWpro/controllers/posture_check.go301 New: nil,
LOWk8s/server/netmaker-ui.yaml41# kind: Ingress
LOWk8s/server/netmaker-ui.yaml61# service:
LOWk8s/server/mosquitto.yaml161# ingressClassName: nginx
LOWk8s/server/netmaker-server.yaml201# kind: Ingress
LOWk8s/server/netmaker-server.yaml221# service:
LOWcompose/docker-compose.pro.yml61 restart: always
LOWlogic/relay.go101// return returnnodes, err
LOWmodels/network_test.go1package models
LOWmigrate/migrate_test.go1// Package migrate provides tests for migration functions, including
LOWscripts/netmaker-ci-runner.sh1#!/usr/bin/env bash
LOWscripts/nm-quick.sh841# setup_mesh - sets up a default mesh network on the server
LOWcontrollers/enrollmentkeys.go221 })
LOWcontrollers/dns.go61}
LOWcontrollers/dns.go321// @Summary Delete Nameserver Resource
LOWcontrollers/dns.go481 json.NewEncoder(w).Encode(dns)
LOWcontrollers/egress.go21func egressHandlers(r *mux.Router) {
LOWcontrollers/server.go121 licenseErr := ""
LOWcontrollers/server.go181// @Produce json
LOWcontrollers/server.go221// @Produce json
LOWcontrollers/user.go541 }, "totp setup initiated")
LOWcontrollers/user.go901// @Security oauth
LOWcontrollers/user.go1021 logger.Log(2, r.Header.Get("user"), "fetched users")
LOWcontrollers/user.go1601 }
LOWcontrollers/user_test.go1package controller
LOWcontrollers/user_test.go21
LOWcontrollers/user_test.go41// bits, err := json.Marshal(userForBody)
LOWcontrollers/user_test.go61
LOWcontrollers/user_test.go81// assert.False(t, found)
LOWcontrollers/user_test.go101// err := logic.CreateUser(&user)
LOWcontrollers/user_test.go121// }
LOWcontrollers/user_test.go141// func TestDeleteUser(t *testing.T) {
LOWcontrollers/user_test.go161// t.Run("Valid Create", func(t *testing.T) {
LOWcontrollers/user_test.go181// t.Skip()
LOWcontrollers/user_test.go201// err := logic.ValidateUser(&user)
LOWcontrollers/user_test.go221// assert.Nil(t, err)
LOWcontrollers/user_test.go241// }
LOWcontrollers/user_test.go261
LOWcontrollers/user_test.go281// })
LOWcontrollers/user_test.go301// // })
LOWcontrollers/user_test.go321// authRequest.Password = ""
LOWcontrollers/user_test.go341// jwt, err := logic.VerifyAuthRequest(authRequest)
LOWcontrollers/hosts.go201 logic.SortApiHosts(apiHosts[:])
LOWcontrollers/network.go181// @Summary Delete a network
LOWcontrollers/ext_client.go141 json.NewEncoder(w).Encode(clients)
LOWcontrollers/ext_client.go181 json.NewEncoder(w).Encode(client)
LOWcontrollers/ext_client.go661}
5 more matches not shown…
AI Slop Vocabulary1 hit · 3 pts
SeverityFileLineSnippet
MEDIUMservercfg/serverconf.go840// - Most robust but adds infrastructure dependency