Class BammBammClient

java.lang.Object
org.shredzone.acme4j.it.BammBammClient

public class BammBammClient extends Object
The BammBamm client connects to the pebble-challtestsrv.
  • Constructor Details

    • BammBammClient

      public BammBammClient(String baseUrl)
      Creates a new BammBamm client.
      Parameters:
      baseUrl - Base URL of the pebble-challtestsrv server to connect to.
  • Method Details

    • httpAddToken

      public void httpAddToken(String token, String challenge) throws IOException
      Adds a HTTP token.
      Parameters:
      token - Token to add
      challenge - Challenge to respond with
      Throws:
      IOException
    • httpRemoveToken

      public void httpRemoveToken(String token) throws IOException
      Removes a HTTP token.
      Parameters:
      token - Token to remove
      Throws:
      IOException
    • dnsAddARecord

      public void dnsAddARecord(String domain, String ip) throws IOException
      Adds an A Record to the DNS. Only one A Record is supported per domain. If another A Record is set, it will replace the existing one.
      Parameters:
      domain - Domain of the A Record
      ip - IP address or domain name. If a domain name is used, it will be resolved and the IP will be used.
      Throws:
      IOException
    • dnsRemoveARecord

      public void dnsRemoveARecord(String domain) throws IOException
      Removes an A Record from the DNS.
      Parameters:
      domain - Domain to remove the A Record from
      Throws:
      IOException
    • dnsAddTxtRecord

      public void dnsAddTxtRecord(String domain, String txt) throws IOException
      Adds a TXT Record to the DNS. Only one TXT Record is supported per domain. If another TXT Record is set, it will replace the existing one.
      Parameters:
      domain - Domain name to add the TXT Record to
      txt - TXT record to add
      Throws:
      IOException
    • dnsRemoveTxtRecord

      public void dnsRemoveTxtRecord(String domain) throws IOException
      Removes a TXT Record from the DNS.
      Parameters:
      domain - Domain to remove the TXT Record from
      Throws:
      IOException
    • dnsAddCnameRecord

      public void dnsAddCnameRecord(String domain, String cname) throws IOException
      Adds a CNAME Record to the DNS. Only one CNAME Record is supported per domain. If another CNAME Record is set, it will replace the existing one.
      Parameters:
      domain - Domain to add the CNAME Record to
      cname - CNAME Record to add
      Throws:
      IOException
      Since:
      2.9
    • dnsRemoveCnameRecord

      public void dnsRemoveCnameRecord(String domain) throws IOException
      Removes a CNAME Record from the DNS.
      Parameters:
      domain - Domain to remove the CNAME Record from
      Throws:
      IOException
      Since:
      2.9
    • dnsAddServFailRecord

      public void dnsAddServFailRecord(String domain) throws IOException
      Simulates a SERVFAIL for the given domain.
      Parameters:
      domain - Domain that will give a SERVFAIL response
      Throws:
      IOException
      Since:
      2.9
    • dnsRemoveServFailRecord

      public void dnsRemoveServFailRecord(String domain) throws IOException
      Removes a SERVFAIL Record from the DNS.
      Parameters:
      domain - Domain to remove the SEVFAIL Record from
      Throws:
      IOException
      Since:
      2.9
    • tlsAlpnAddCertificate

      public void tlsAlpnAddCertificate(String domain, String keyauth) throws IOException
      Adds a certificate for TLS-ALPN tests.
      Parameters:
      domain - Certificate domain to be added
      keyauth - Key authorization to be used for validation
      Throws:
      IOException
    • tlsAlpnRemoveCertificate

      public void tlsAlpnRemoveCertificate(String domain) throws IOException
      Removes a certificate.
      Parameters:
      domain - Certificate domain to be removed
      Throws:
      IOException