| Server IP : 172.67.134.114 / Your IP : 104.23.197.123 Web Server : Apache/2.4.37 System : Linux almalinux.duckdns.org 4.18.0-553.111.1.el8_10.x86_64 #1 SMP Sun Mar 8 20:06:07 EDT 2026 x86_64 User : ricodeal ( 1046) PHP Version : 7.4.33 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : ON | Pkexec : ON Directory : /usr/libexec/usermin/authentic-theme/ |
Upload File : |
#
# Authentic Theme (https://github.com/webmin/authentic-theme)
# Copyright Ilia Ross <[email protected]>
# Licensed under MIT (https://github.com/webmin/authentic-theme/blob/master/LICENSE)
#
use strict;
use warnings;
require("$ENV{'THEME_ROOT'}/login-lib-funcs.pl");
our (%gconfig, $config_directory, $pragma_no_cache, $current_theme);
our ($miniserv, $webprefix, $bg, $textbox_attrs, $hostname);
# Use config from miniserv
$miniserv = \%miniserv::config;
# Load the theme library
load_theme_library();
# Set basic variables
$webprefix = &get_webprefix();
$bg = theme_night_mode_login() ? "nightRider" : "gainsboro";
$textbox_attrs = sub {
my $complete = shift;
$complete ||= $gconfig{'noremember'} ? "off" : "username";
return "autocomplete=$complete autocorrect=off autocapitalize=none";
};
# Check to add error handler
error_40x_handler();
# Collect theme configs
my %theme_config = (
settings("$config_directory/$current_theme/settings.js", 'settings_'),
settings("$config_directory/$current_theme/settings-admin", 'settings_'),
settings("$config_directory/$current_theme/settings-root", 'settings_'));
# Get hostname
if ($theme_config{'settings_login_page_server_name'}) {
$hostname = $theme_config{'settings_login_page_server_name'};
}
elsif ($gconfig{'realname'}) {
$hostname = &get_display_hostname();
}
else {
$hostname = get_env('server_name');
$hostname =~ s/:\d+//g;
$hostname = &html_escape($hostname);
}
# Never cache
$pragma_no_cache = 1;
1;