Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/Mawthuq-Software/Wireguard-Manager-and-API
/ functions
Functions
55 in github.com/Mawthuq-Software/Wireguard-Manager-and-API
⨍
Functions
55
◇
Types & classes
15
↓ 28 callers
Function
sentStandardRes
(res http.ResponseWriter, responseMap map[string]string, httpStatusCode int)
src/api/router/sendResponse.go:10
↓ 15 callers
Function
ErrorHandler
(message string, err error)
src/logger/errorHandler.go:5
↓ 6 callers
Function
parseResponse
(req *http.Request, schema interface{})
src/api/router/parseResponse.go:9
↓ 5 callers
Function
closeInstance
(client *wgctrl.Client)
src/manager/manager.go:25
↓ 5 callers
Function
createInstance
()
src/manager/manager.go:21
↓ 4 callers
Function
ParseIP
(address string)
src/manager/manager.go:47
↓ 4 callers
Function
ParseKey
(key string)
src/manager/manager.go:40
↓ 4 callers
Function
addIP
(instance netlink.Link, ipAddr *netlink.Addr)
src/network/network.go:22
↓ 2 callers
Function
AddKey
(interfaceName string, ipv4Address string, ipv6Address string, publicStr string, presharedStr string)
src/manager/addKey.go:12
↓ 2 callers
Function
AddPeersInterface
(interfaceName string, pk string, listenPort int, peers []wgtypes.PeerConfig)
src/manager/addPeersInterface.go:10
↓ 2 callers
Function
DeleteKey
(interfaceName string, publicStr string)
src/manager/deleteKey.go:10
↓ 2 callers
Function
DisableKey
(keyID string)
src/db/disableKey.go:11
↓ 2 callers
Function
GetInterfaces
()
src/manager/getInterfaces.go:11
↓ 2 callers
Function
createWG
(PrivateKey string, PublicKey string, ListenPort int, IPv4Address string, IPv6Address string)
src/db/createWG.go:7
↓ 2 callers
Function
generatePeerArray
()
src/db/generatePeerArray.go:14
↓ 2 callers
Function
sendKeysRes
(res http.ResponseWriter, responseStruct db.ReturnKeysRes, httpStatusCode int)
src/api/router/sendResponse.go:17
↓ 2 callers
Function
sendSubsRes
(res http.ResponseWriter, responseStruct db.ReturnSubsRes, httpStatusCode int)
src/api/router/sendResponse.go:24
↓ 2 callers
Function
updatePeerBW
(currentPeer wgtypes.Peer)
src/db/dbAutoChecks.go:76
↓ 1 callers
Function
API
()
src/api/apiServer.go:17
↓ 1 callers
Function
AddRemovePeer
(peer wgtypes.Peer, wgIntName string)
src/manager/addRemovePeer.go:11
↓ 1 callers
Function
AddRemovePeers
()
src/db/dbAutoChecks.go:15
↓ 1 callers
Function
AutoStart
()
src/autocheck/autocheck.go:11
↓ 1 callers
Function
BWPeerCheck
()
src/db/dbAutoChecks.go:34
↓ 1 callers
Function
CreateKey
(pubKey string, preKey string, bwLimit int64, subEnd string, ipIndex int)
src/db/createKey.go:15
↓ 1 callers
Function
DBStart
()
src/db/db.go:17
↓ 1 callers
Function
DeleteKey
(keyID string)
src/db/deleteKey.go:12
↓ 1 callers
Function
EnableKey
(keyID string)
src/db/enableKey.go:11
↓ 1 callers
Function
GetUserSubscription
(keyID string)
src/db/subscription.go:8
↓ 1 callers
Function
LoadConfig
()
src/config/config.go:7
↓ 1 callers
Function
LoggerSetup
()
src/logger/logger.go:10
↓ 1 callers
Function
NewRouter
()
src/api/router/router.go:9
↓ 1 callers
Function
ReturnKeys
()
src/db/returnKeys.go:14
↓ 1 callers
Function
ReturnSubscriptions
()
src/db/returnSubscriptions.go:14
↓ 1 callers
Function
SetSubscription
(keyID string, bwLimit int64, subExpiry string, bwReset bool)
src/db/setSubscription.go:11
↓ 1 callers
Function
SetupWG
()
src/network/network.go:12
↓ 1 callers
Function
WGStart
()
src/db/wgServerStartup.go:12
↓ 1 callers
Function
generateIPs
()
src/db/db.go:40
↓ 1 callers
Function
ipCheck
(wg0 netlink.Link)
src/network/network.go:32
↓ 1 callers
Function
returnNewLink
(l Link)
src/manager/manager.go:36
Method
Attrs
https://github.com/vishvananda/netlink/blob/master/link.go
src/manager/manager.go:13
Method
Attrs
()
src/manager/manager.go:30
Method
Type
()
src/manager/manager.go:14
Method
Type
()
src/manager/manager.go:33
Function
authMiddleware
(handler http.Handler)
src/api/router/authMiddleware.go:9
Function
getKeySub
(res http.ResponseWriter, req *http.Request)
src/api/router/getKeySubscription.go:14
Function
getKeys
(res http.ResponseWriter, req *http.Request)
src/api/router/getKeys.go:9
Function
getSubscriptions
(res http.ResponseWriter, req *http.Request)
src/api/router/getSubscriptions.go:9
Function
keyCreate
(res http.ResponseWriter, req *http.Request)
src/api/router/keyCreate.go:18
Function
keyDisable
(res http.ResponseWriter, req *http.Request)
src/api/router/keyDisable.go:14
Function
keyEnable
(res http.ResponseWriter, req *http.Request)
src/api/router/keyEnable.go:14
Function
keyRemove
(res http.ResponseWriter, req *http.Request)
src/api/router/keyRemove.go:14
Function
keySetSubscription
(res http.ResponseWriter, req *http.Request)
src/api/router/keySetSubcription.go:17
Function
main
()
main.go:15
Function
setCorsHeader
(res http.ResponseWriter, req *http.Request)
src/api/router/headerMiddleware.go:21
Function
setHeader
(hand http.Handler)
src/api/router/headerMiddleware.go:7