config = @parse_ini_file($config_path); if ($this->config === false) { throw new Exception("Failed to parse configuration at {$config_path}"); } } public function getDbDriver(): string { $driver = $this->config['driver'] ?? "PDO_PGSQL"; return $driver; } public function getDbFile(): string { $file = $this->config['file'] ?? "./request.db"; return $file; } public function getDbHost(): string { $host = $this->config['host'] ?? "localhost"; return $host; } public function getDbPort(): int { $port = $this->config['port'] ?? 5432; return $port; } public function getDbBase(): string { $database = $this->config['database'] ?? "requests"; return $database; } public function getDbUser(): string { $user = $this->config['user'] ?? "matrixadmin"; return $user; } public function getDbPass(): string { $password = $this->config['password'] ?? "geheim"; return $password; } public function getLogLevel(): int { $loglevel = strtoupper($this->config['loglevel']) ?? LOG_INFO; return $loglevel; } public function getLogFile(): string { $logfile = $this->config['logfile'] ?? "log/register.log"; return $logfile; } public function getMxDomain(): string { $driver = $this->config['mxdomain'] ?? "matrix.kraut.space"; return $driver; } public function getBaseURL(): string { $baseurl = $this->config['baseurl'] ?? ""; return $baseurl; } public function getValidator(): string { $validator = $this->config['validator'] ?? "validation.php?token="; return $validator; } public function getMailFrom(): string { $mailfrom = $this->config['mailfrom'] ?? ""; return $mailfrom; } public function getMailSubject(): string { $mailsubject = $this->config['mailsubject'] ?? "Ihr Matrix Account"; return $mailsubject; } public function getMailClosure(): string { $mailclosure = $this->config['mailclosure'] ?? "MfG"; return $mailclosure; } } ?>