Skip to content

Invalid domain used when ldap record doesn't have email field #21169

Closed
@pezhovski

Description

@pezhovski

Description

When syncing users from ldap, if user doesn't have email field, username@localhost is used https://github.com/go-gitea/gitea/blob/v1.17.2/services/auth/source/ldap/source_sync.go#L88

Later when trying to edit this user from admin page, I'm getting an error that email is invalid

Gitea Version

1.17.0

Can you reproduce the bug on the Gitea demo site?

No

Log Gist

No response

Screenshots

No response

Git Version

No response

Operating System

No response

How are you running Gitea?

Downloaded binary from release page, run with systemd

Database

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions