Documentation
¶
Index ¶
- func GetChallengeForConnection(pubKey string) string
- func HandleAuth(client nostr.ClientInterface, message []interface{})
- func HandleClose(client nostr.ClientInterface, message []interface{})
- func HandleEvent(client nostr.ClientInterface, message []interface{})
- func HandleReq(client nostr.ClientInterface, message []interface{})
- func IsAuthenticated(client nostr.ClientInterface) bool
- func SetAuthenticated(client nostr.ClientInterface)
- func SetChallengeForConnection(pubKey, challenge string)
- func VerifyAuthEvent(evt nostr.Event) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetChallengeForConnection ¶
GetChallengeForConnection retrieves the challenge string for a given connection
func HandleAuth ¶
func HandleAuth(client nostr.ClientInterface, message []interface{})
HandleAuth processes the "AUTH" message type as defined in NIP-42
func HandleClose ¶
func HandleClose(client nostr.ClientInterface, message []interface{})
HandleClose processes a "CLOSE" message from a client
func HandleEvent ¶
func HandleEvent(client nostr.ClientInterface, message []interface{})
HandleEvent processes an "EVENT" message
func HandleReq ¶
func HandleReq(client nostr.ClientInterface, message []interface{})
HandleReq processes a new subscription request with proper subscription management
func IsAuthenticated ¶
func IsAuthenticated(client nostr.ClientInterface) bool
IsAuthenticated checks if a connection is authenticated
func SetAuthenticated ¶
func SetAuthenticated(client nostr.ClientInterface)
SetAuthenticated marks a connection as authenticated
func SetChallengeForConnection ¶
func SetChallengeForConnection(pubKey, challenge string)
SetChallengeForConnection sets the challenge string for a given connection
func VerifyAuthEvent ¶
VerifyAuthEvent verifies the authentication event according to NIP-42
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.