Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 12 additions & 2 deletions epp.php
Original file line number Diff line number Diff line change
Expand Up @@ -573,7 +573,17 @@ public function registerDomain(Registrar_Domain $domain)
$to[] = $domain->{'get' . ucfirst($ns)}();
$from[] = '/{{ clTRID }}/';
$clTRID = str_replace('.', '', round(microtime(1), 3));
$to[] = htmlspecialchars($this->config['registrarprefix'] . '-host-check-' . $clTRID);
$to[] = htmlspecialchars($this->config['registrarprefix'] . '-host-check-' . $clTRID);

$result = dns_get_record($ns,DNS_A + DNS_AAAA);
foreach ($result as $ip) {
if ($ip['ip']) {
$ips.="\t\t\t ".'<host:addr ip="v4">'.$ip['ip'].'</host:addr>'."\n";
}else if ($ip['ipv6']) {
$ips.="\t\t\t ".'<host:addr ip="v6">'.$ip['ipv6'].'</host:addr>'."\n";
}
$from[] = '/{{ ips }}/';
$to[] = $ips;
$xml = preg_replace($from, $to, '<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<epp xmlns="urn:ietf:params:xml:ns:epp-1.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
Expand All @@ -584,7 +594,7 @@ public function registerDomain(Registrar_Domain $domain)
xmlns:host="urn:ietf:params:xml:ns:host-1.0"
xsi:schemaLocation="urn:ietf:params:xml:ns:host-1.0 host-1.0.xsd">
<host:name>{{ name }}</host:name>
</host:check>
{{ ips }} </host:check>
</check>
<clTRID>{{ clTRID }}</clTRID>
</command>
Expand Down