Gitlab locked login backdoor

Getting into a locked Gitlab instance

Sebastiaan avatar
  • Sebastiaan
  • 1 min read

When locked out of the Gitlab environment, you’ll need to enable default sign-in method when OIDC or AD is configured. This could be done from within the UI, but if you are locked out then this method will ofcourse not work.

Enabling sign-in can also be done from the command line. SSH into the Gitlab server and perform the following command to enable sign-in.

start rails console (takes a while)

gitlab-rails console

Enable

Gitlab::CurrentSettings.update!(password_authentication_enabled_for_web: true)

Disable

Gitlab::CurrentSettings.update!(password_authentication_enabled_for_web: false)
Sebastiaan

Written by : Sebastiaan

Sysadmin/Platform/Devops Engineer

Recommended for You

How to configure Gitlab Advanced Search

How to configure Gitlab Advanced Search

Powering up search in Gitlab

How to do a Gitlab Major version upgrade

How to do a Gitlab Major version upgrade

Easy way to upgrade to a newer version.