1
0
mirror of https://github.com/openshift/openshift-docs.git synced 2026-02-05 12:46:18 +01:00
Files
openshift-docs/modules/identity-provider-creating-htpasswd-file-windows.adoc
2023-10-30 10:13:25 -04:00

48 lines
1.2 KiB
Plaintext

// Module included in the following assemblies:
//
// * authentication/identity_providers/configuring-htpasswd-identity-provider.adoc
:_mod-docs-content-type: PROCEDURE
[id="identity-provider-creating-htpasswd-file-windows_{context}"]
= Creating an htpasswd file using Windows
To use the htpasswd identity provider, you must generate a flat file that
contains the user names and passwords for your cluster by using
link:http://httpd.apache.org/docs/2.4/programs/htpasswd.html[`htpasswd`].
.Prerequisites
* Have access to `htpasswd.exe`. This file is included in the `\bin`
directory of many Apache httpd distributions.
.Procedure
. Create or update your flat file with a user name and hashed password:
+
[source,terminal]
----
> htpasswd.exe -c -B -b <\path\to\users.htpasswd> <username> <password>
----
+
The command generates a hashed version of the password.
+
For example:
+
[source,terminal]
----
> htpasswd.exe -c -B -b users.htpasswd <username> <password>
----
+
.Example output
[source,terminal]
----
Adding password for user user1
----
. Continue to add or update credentials to the file:
+
[source,terminal]
----
> htpasswd.exe -b <\path\to\users.htpasswd> <username> <password>
----