Skip to content

Automatic hashing password #96

Description

@MikyWoW

There should be password in plain text in docker-compose.yml
Using hash is inconvenient.

environment:
            - PHPREDMIN_AUTH_USERNAME=UserName
            - PHPREDMIN_AUTH_PASSWORD=PlainPassword

You can hash it and save somewhere on first run index.php

$hash = GetHash();
if(!$hash){
$pwd = getenv('PHPREDMIN_AUTH_PASSWORD');
$hash = password_hash($pwd, PASSWORD_DEFAULT);
SaveHash($hash);
}
// login method

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions