Skip to content

LDAP Groups Refreshed For Token? #2048

Answered by nabokihms
tjmoyes asked this question in Q&A
Discussion options

You must be logged in to vote

Hello, @tjmoyes.
Yes, it works as you described. If a connector implements the RefreshConnector interface, the Refresh method will be called on token refreshing.

The LDAP refresh method looks like this

dex/connector/ldap/ldap.go

Lines 529 to 568 in 83ad7bc

func (c *ldapConnector) Refresh(ctx context.Context, s connector.Scopes, ident connector.Identity) (connector.Identity, error) {
var data refreshData
if err := json.Unmarshal(ident.ConnectorData, &data); err != nil {
return ident, fmt.Errorf("ldap: failed to unmarshal internal data: %v", err)
}
var user ldap.Entry
err := c.do(ctx, func(conn *ldap.Conn) error {
entry, found, err := c.us…

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@tjmoyes
Comment options

Answer selected by tjmoyes
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants