Fading Coder

One Final Commit for the Last Sprint

Implementing JWT Authentication in Go with Gin Framework

package auth import ( "net/http" "time" "github.com/dgrijalva/jwt-go" "github.com/gin-gonic/gin" ) const secretKey = "application_secret_key" type AuthController struct{} type UserCredentials struct { Username string `json:"username"` Pass...

Real-Time Messaging in Go with Gin and Gorilla WebSocket

Add WebSocket endpoints to a Gin-based Go service using Gorillla WebSocket, plus a minimal browser client to exercise both text and JSON message flows. WebSocket libray The server uses Gorilla WebSocket to the protocol upgrade and message I/O: github.com/gorilla/websocket Backend (Go) The server exp...