mirror of
https://github.com/getnamingo/registry.git
synced 2025-07-25 03:48:24 +02:00
Small fixes
This commit is contained in:
parent
3c6504ef9e
commit
f3cbf5b2af
4 changed files with 9 additions and 8 deletions
|
@ -11,7 +11,7 @@ $server->set([
|
||||||
'log_file' => '/var/log/das/das.log',
|
'log_file' => '/var/log/das/das.log',
|
||||||
'log_level' => SWOOLE_LOG_INFO,
|
'log_level' => SWOOLE_LOG_INFO,
|
||||||
'worker_num' => swoole_cpu_num() * 2,
|
'worker_num' => swoole_cpu_num() * 2,
|
||||||
'pid_file' => '/var/log/das/das.pid',
|
'pid_file' => '/var/run/das.pid',
|
||||||
'max_request' => 1000,
|
'max_request' => 1000,
|
||||||
'dispatch_mode' => 2,
|
'dispatch_mode' => 2,
|
||||||
'open_tcp_nodelay' => true,
|
'open_tcp_nodelay' => true,
|
||||||
|
|
|
@ -129,8 +129,9 @@ function processDomainCheck($conn, $db, $xml, $trans) {
|
||||||
$domainEntry[] = 'In use';
|
$domainEntry[] = 'In use';
|
||||||
} else {
|
} else {
|
||||||
// Check if the domain is reserved
|
// Check if the domain is reserved
|
||||||
|
$parts = explode('.', $domainName);
|
||||||
$stmt = $db->prepare("SELECT type FROM reserved_domain_names WHERE name = :domainName LIMIT 1");
|
$stmt = $db->prepare("SELECT type FROM reserved_domain_names WHERE name = :domainName LIMIT 1");
|
||||||
$stmt->bindParam(':domainName', $domainName, PDO::PARAM_STR);
|
$stmt->bindParam(':domainName', $parts[0], PDO::PARAM_STR);
|
||||||
$stmt->execute();
|
$stmt->execute();
|
||||||
$reserved = $stmt->fetchColumn();
|
$reserved = $stmt->fetchColumn();
|
||||||
|
|
||||||
|
|
|
@ -63,7 +63,7 @@ $http->set([
|
||||||
'log_file' => '/var/log/rdap/rdap.log',
|
'log_file' => '/var/log/rdap/rdap.log',
|
||||||
'log_level' => SWOOLE_LOG_INFO,
|
'log_level' => SWOOLE_LOG_INFO,
|
||||||
'worker_num' => swoole_cpu_num() * 2,
|
'worker_num' => swoole_cpu_num() * 2,
|
||||||
'pid_file' => '/var/log/rdap/rdap.pid',
|
'pid_file' => '/var/run/rdap.pid',
|
||||||
'max_request' => 1000,
|
'max_request' => 1000,
|
||||||
'dispatch_mode' => 1,
|
'dispatch_mode' => 1,
|
||||||
'open_tcp_nodelay' => true,
|
'open_tcp_nodelay' => true,
|
||||||
|
@ -397,13 +397,13 @@ function handleDomainQuery($request, $response, $pdo, $domainName, $c) {
|
||||||
[
|
[
|
||||||
mapContactToVCard($registrantDetails, 'registrant', $c)
|
mapContactToVCard($registrantDetails, 'registrant', $c)
|
||||||
],
|
],
|
||||||
array_map(function ($contact) {
|
array_map(function ($contact) use ($c) {
|
||||||
return mapContactToVCard($contact, 'admin', $c);
|
return mapContactToVCard($contact, 'admin', $c);
|
||||||
}, $adminDetails),
|
}, $adminDetails),
|
||||||
array_map(function ($contact) {
|
array_map(function ($contact) use ($c) {
|
||||||
return mapContactToVCard($contact, 'tech', $c);
|
return mapContactToVCard($contact, 'tech', $c);
|
||||||
}, $techDetails),
|
}, $techDetails),
|
||||||
array_map(function ($contact) {
|
array_map(function ($contact) use ($c) {
|
||||||
return mapContactToVCard($contact, 'billing', $c);
|
return mapContactToVCard($contact, 'billing', $c);
|
||||||
}, $billingDetails)
|
}, $billingDetails)
|
||||||
),
|
),
|
||||||
|
@ -422,7 +422,7 @@ function handleDomainQuery($request, $response, $pdo, $domainName, $c) {
|
||||||
'type' => 'application/rdap+json',
|
'type' => 'application/rdap+json',
|
||||||
]
|
]
|
||||||
],
|
],
|
||||||
'nameservers' => array_map(function ($nameserverDetails) {
|
'nameservers' => array_map(function ($nameserverDetails) use ($c) {
|
||||||
return [
|
return [
|
||||||
'objectClassName' => 'nameserver',
|
'objectClassName' => 'nameserver',
|
||||||
'handle' => 'H' . $nameserverDetails['host_id'] . '-' . $c['roid'] . '',
|
'handle' => 'H' . $nameserverDetails['host_id'] . '-' . $c['roid'] . '',
|
||||||
|
|
|
@ -11,7 +11,7 @@ $server->set([
|
||||||
'log_file' => '/var/log/whois/whois.log',
|
'log_file' => '/var/log/whois/whois.log',
|
||||||
'log_level' => SWOOLE_LOG_INFO,
|
'log_level' => SWOOLE_LOG_INFO,
|
||||||
'worker_num' => swoole_cpu_num() * 2,
|
'worker_num' => swoole_cpu_num() * 2,
|
||||||
'pid_file' => '/var/log/whois/whois.pid',
|
'pid_file' => '/var/run/whois.pid',
|
||||||
'max_request' => 1000,
|
'max_request' => 1000,
|
||||||
'dispatch_mode' => 2,
|
'dispatch_mode' => 2,
|
||||||
'open_tcp_nodelay' => true,
|
'open_tcp_nodelay' => true,
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue