Merge pull request #3066 from jan-win1993/acme-udr

Add udr challenge type
This commit is contained in:
Frank Wall
2022-08-03 18:13:07 +02:00
committed by GitHub
3 changed files with 67 additions and 0 deletions
@@ -1098,6 +1098,21 @@
<type>textbox</type>
<help>Requires the whole key file in a format that is compatible with TransIP.</help>
</field>
<field>
<label>united-domains Reselling</label>
<type>header</type>
<style>table_dns table_dns_udr</style>
</field>
<field>
<id>validation.dns_udr_user</id>
<label>User</label>
<type>text</type>
</field>
<field>
<id>validation.dns_udr_password</id>
<label>Password</label>
<type>password</type>
</field>
<field>
<label>UnoEuro</label>
<type>header</type>
@@ -0,0 +1,45 @@
<?php
/*
* Copyright (C) 2022 Jan Winkler
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
* THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES,
* INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY
* AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
* AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY,
* OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
* SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
* INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
* CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
* POSSIBILITY OF SUCH DAMAGE.
*/
namespace OPNsense\AcmeClient\LeValidation;
use OPNsense\AcmeClient\LeValidationInterface;
use OPNsense\Core\Config;
/**
* udr API
* @package OPNsense\AcmeClient
*/
class DnsUdr extends Base implements LeValidationInterface
{
public function prepare()
{
$this->acme_env['UDR_USER'] = (string)$this->config->dns_udr_user;
$this->acme_env['UDR_PASS'] = (string)$this->config->dns_udr_password;
}
}
@@ -492,6 +492,7 @@
<dns_servercow>Servercow</dns_servercow>
<dns_simply>Simply.com</dns_simply>
<dns_transip>Transip</dns_transip>
<dns_udr>united-domains Reselling</dns_udr>
<dns_unoeuro>UnoEuro</dns_unoeuro>
<dns_variomedia>Variomedia.de</dns_variomedia>
<dns_vscale>Vscale</dns_vscale>
@@ -964,6 +965,12 @@
<dns_transip_key type="TextField">
<Required>N</Required>
</dns_transip_key>
<dns_udr_user type="TextField">
<Required>N</Required>
</dns_udr_user>
<dns_udr_password type="TextField">
<Required>N</Required>
</dns_udr_password>
<dns_uno_key type="TextField">
<Required>N</Required>
</dns_uno_key>