We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent db71cae commit fc8b69fCopy full SHA for fc8b69f
pkg/api/auth.go
@@ -180,6 +180,7 @@ func (h APIHandler) samlConnecter(c *gin.Context) {
180
181
data := c.Request.Form
182
samlResponseData := data.Get("SAMLResponse")
183
+ fmt.Println(samlResponseData)
184
185
samlResponse, err := saml.Verify(
186
samlResponseData,
@@ -194,11 +195,12 @@ func (h APIHandler) samlConnecter(c *gin.Context) {
194
195
return
196
}
197
username := samlResponse.Assertion.Subject.NameID.Value
198
+
199
if err != nil {
200
c.AbortWithError(http.StatusNotAcceptable, fmt.Errorf("username not found"))
201
202
-
203
+ // -- belove this line is how we handle users that are authenticatd
204
jwtToken, err := generateJWT(username, 12)
205
206
c.AbortWithError(http.StatusNotAcceptable, err)
0 commit comments