Skip to content

Commit

Permalink
cherry pick #27558 to release-5.2
Browse files Browse the repository at this point in the history
Signed-off-by: ti-srebot <ti-srebot@pingcap.com>
  • Loading branch information
dveeden authored and ti-srebot committed Aug 24, 2021
1 parent 3d88be8 commit 159860b
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions privilege/privileges/privileges.go
Original file line number Diff line number Diff line change
Expand Up @@ -221,6 +221,10 @@ func (p *UserPrivileges) GetEncodedPassword(user, host string) string {

// GetAuthPlugin gets the authentication plugin for the account identified by the user and host
func (p *UserPrivileges) GetAuthPlugin(user, host string) (string, error) {
if SkipWithGrant {
return mysql.AuthNativePassword, nil
}

mysqlPriv := p.Handle.Get()
record := mysqlPriv.connectionVerification(user, host)
if record == nil {
Expand Down

0 comments on commit 159860b

Please sign in to comment.