mirror of
https://github.com/DanWin/mail-hosting.git
synced 2024-11-21 23:20:25 +00:00
9 lines
400 B
PHP
9 lines
400 B
PHP
<?php
|
|
const ADMIN_USER='admin';
|
|
const ADMIN_PASS='YOUR_PASSWORD';
|
|
|
|
require_once __DIR__ . '/../common_config.php';
|
|
$db = get_db_instance();
|
|
$hash = password_hash( ADMIN_PASS, PASSWORD_ARGON2ID );
|
|
$stmt = $db->prepare( 'INSERT INTO admin (password_hash_type, password, superadmin, username, created, modified) VALUES ("{ARGON2ID}", ?, 1, ?, NOW(), NOW());' );
|
|
$stmt->execute( [ $hash, ADMIN_USER ] );
|