Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

epik: returns 404 #2268

Closed
3 tasks done
Teuwu opened this issue Sep 8, 2024 · 8 comments · Fixed by #2290
Closed
3 tasks done

epik: returns 404 #2268

Teuwu opened this issue Sep 8, 2024 · 8 comments · Fixed by #2290

Comments

@Teuwu
Copy link

Teuwu commented Sep 8, 2024

Welcome

  • Yes, I'm using a binary release within 2 latest releases.
  • Yes, I've searched similar issues on GitHub and didn't find any.
  • Yes, I've included all information below (version, config, etc).

What did you expect to see?

I expected to renew/run a cert with the dns backend of epik.

What did you see instead?

404 error

How do you use lego?

Binary

Reproduction steps

this is my script,

#!/bin/bash

export EPIK_SIGNATURE=[REDACTED]
export EPIK_PROPAGATION_TIMEOUT=900
export EPIK_POLLING_INTERVAL=30
export EPIK_TTL=300
/usr/local/bin/lego --email [REDACTED] --dns epik --domains *.[REDACTED] renew
/usr/local/bin/lego --email [REDACTED] --dns epik --domains *.[REDACTED] --domains [REDACTED] renew

Version of lego

lego version 4.18.0 linux/amd64

Logs

2024/09/08 [REDACTED] [INFO] [[REDACTED]] acme: Trying renewal with -2699 hours remaining
2024/09/08 [REDACTED] [INFO] [[REDACTED], *.[REDACTED]] acme: Obtaining bundled SAN certificate
2024/09/08 [REDACTED] [INFO] [*.[REDACTED]] AuthURL: https://acme-v02.api.letsencrypt.org/acme/authz-v3/401146463086
2024/09/08 [REDACTED] [INFO] [[REDACTED]] AuthURL: https://acme-v02.api.letsencrypt.org/acme/authz-v3/401146463096
2024/09/08 [REDACTED] [INFO] [*.[REDACTED]] acme: use dns-01 solver
2024/09/08 [REDACTED] [INFO] [[REDACTED]] acme: Could not find solver for: tls-alpn-01
2024/09/08 [REDACTED] [INFO] [[REDACTED]] acme: Could not find solver for: http-01
2024/09/08 [REDACTED] [INFO] [[REDACTED]] acme: use dns-01 solver
2024/09/08 [REDACTED] [INFO] [*.[REDACTED]] acme: Preparing to solve DNS-01
2024/09/08 [REDACTED] [INFO] [[REDACTED]] acme: Preparing to solve DNS-01
2024/09/08 [REDACTED] [INFO] [*.[REDACTED]] acme: Cleaning DNS-01 challenge
2024/09/08 [REDACTED] [WARN] [*.[REDACTED]] acme: cleaning up failed: epik: 404: <!doctype html>
<html lang="en-US" class="no-js">
<head>
    <meta charset="UTF-8">
    <title> Page not found - Epik</title>
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <link rel="icon" type="image/png" sizes="32x32"
          href="https://www.epik.com/wp-content/themes/epik-redesign/src/img/favicon.png">
    <meta name="theme-color" content="#ffffff">
    <meta name='robots' content='noindex, follow'/>
</head>
<body class="error404">
<div id="body-content" class="wrapper">
    <main class="e404-page" role="main" id="main-content">
        <div class="container-fluid">
            <div class="row">
                <div class="col-lg-6 pt-5 pb-5 text-side">
                    <div class="content-wrapper">
                        <div class="header-wrapper">
                            <h1>404 <span class="e404-header-smaller">Page not found</span></h1>
                        </div>
                        <div class="text-wrapper">
                            <p>Whoops, the link you clicked may be broken or the page may have been removed.</p>
                            <p>Return to the <a href="https://www.epik.com">homepage</a> to get back on track or <a
                                    href="/contact/">contact us</a> for assistance.</p>
                        </div>
                    </div>
                </div>
                <div class="d-none d-lg-block col-lg-6 background-side"></div>
            </div>
        </div>
    </main>
</div>
<script>(function(){function c(){var b=a.contentDocument||a.contentWindow.document;if(b){var d=b.createElement('script');d.innerHTML="window.__CF$cv$params={r:'8c02a2027b63d7a7',t:'MTcyNTgzNzI0NS4wMDAwMDA='};var a=document.createElement('script');a.nonce='';a.src='/cdn-cgi/challenge-platform/scripts/jsd/main.js';document.getElementsByTagName('head')[0].appendChild(a);";b.getElementsByTagName('head')[0].appendChild(d)}}if(document.body){var a=document.createElement('iframe');a.height=1;a.width=1;a.style.position='absolute';a.style.top=0;a.style.left=0;a.style.border='none';a.style.visibility='hidden';document.body.appendChild(a);if('loading'!==document.readyState)c();else if(window.addEventListener)document.addEventListener('DOMContentLoaded',c);else{var e=document.onreadystatechange||function(){};document.onreadystatechange=function(b){e(b);'loading'!==document.readyState&&(document.onreadystatechange=e,c())}}}})();</script></body>
</html>
 
2024/09/08 [REDACTED] [INFO] [[REDACTED]] acme: Cleaning DNS-01 challenge
2024/09/08 [REDACTED] [WARN] [[REDACTED]] acme: cleaning up failed: epik: 404: <!doctype html>
<html lang="en-US" class="no-js">
<head>
    <meta charset="UTF-8">
    <title> Page not found - Epik</title>
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <link rel="icon" type="image/png" sizes="32x32"
          href="https://www.epik.com/wp-content/themes/epik-redesign/src/img/favicon.png">
    <meta name="theme-color" content="#ffffff">
    <meta name='robots' content='noindex, follow'/>
</head>
<body class="error404">
<div id="body-content" class="wrapper">
    <main class="e404-page" role="main" id="main-content">
        <div class="container-fluid">
            <div class="row">
                <div class="col-lg-6 pt-5 pb-5 text-side">
                    <div class="content-wrapper">
                        <div class="header-wrapper">
                            <h1>404 <span class="e404-header-smaller">Page not found</span></h1>
                        </div>
                        <div class="text-wrapper">
                            <p>Whoops, the link you clicked may be broken or the page may have been removed.</p>
                            <p>Return to the <a href="https://www.epik.com">homepage</a> to get back on track or <a
                                    href="/contact/">contact us</a> for assistance.</p>
                        </div>
                    </div>
                </div>
                <div class="d-none d-lg-block col-lg-6 background-side"></div>
            </div>
        </div>
    </main>
</div>
<script>(function(){function c(){var b=a.contentDocument||a.contentWindow.document;if(b){var d=b.createElement('script');d.innerHTML="window.__CF$cv$params={r:'8c02a202dcdbd7a7',t:'MTcyNTgzNzI0NS4wMDAwMDA='};var a=document.createElement('script');a.nonce='';a.src='/cdn-cgi/challenge-platform/scripts/jsd/main.js';document.getElementsByTagName('head')[0].appendChild(a);";b.getElementsByTagName('head')[0].appendChild(d)}}if(document.body){var a=document.createElement('iframe');a.height=1;a.width=1;a.style.position='absolute';a.style.top=0;a.style.left=0;a.style.border='none';a.style.visibility='hidden';document.body.appendChild(a);if('loading'!==document.readyState)c();else if(window.addEventListener)document.addEventListener('DOMContentLoaded',c);else{var e=document.onreadystatechange||function(){};document.onreadystatechange=function(b){e(b);'loading'!==document.readyState&&(document.onreadystatechange=e,c())}}}})();</script></body>
</html>
 
2024/09/08 23:14:05 [INFO] Deactivating auth: https://acme-v02.api.letsencrypt.org/acme/authz-v3/401146463086
2024/09/08 23:14:06 [INFO] Deactivating auth: https://acme-v02.api.letsencrypt.org/acme/authz-v3/401146463096
2024/09/08 23:14:06 error: one or more domains had a problem:
[*.[REDACTED]] [*.[REDACTED]] acme: error presenting token: epik: 404: <!doctype html>
<html lang="en-US" class="no-js">
<head>
    <meta charset="UTF-8">
    <title> Page not found - Epik</title>
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <link rel="icon" type="image/png" sizes="32x32"
          href="https://www.epik.com/wp-content/themes/epik-redesign/src/img/favicon.png">
    <meta name="theme-color" content="#ffffff">
    <meta name='robots' content='noindex, follow'/>
</head>
<body class="error404">
<div id="body-content" class="wrapper">
    <main class="e404-page" role="main" id="main-content">
        <div class="container-fluid">
            <div class="row">
                <div class="col-lg-6 pt-5 pb-5 text-side">
                    <div class="content-wrapper">
                        <div class="header-wrapper">
                            <h1>404 <span class="e404-header-smaller">Page not found</span></h1>
                        </div>
                        <div class="text-wrapper">
                            <p>Whoops, the link you clicked may be broken or the page may have been removed.</p>
                            <p>Return to the <a href="https://www.epik.com">homepage</a> to get back on track or <a
                                    href="/contact/">contact us</a> for assistance.</p>
                        </div>
                    </div>
                </div>
                <div class="d-none d-lg-block col-lg-6 background-side"></div>
            </div>
        </div>
    </main>
</div>
<script>(function(){function c(){var b=a.contentDocument||a.contentWindow.document;if(b){var d=b.createElement('script');d.innerHTML="window.__CF$cv$params={r:'8c02a1eb09b4d7a7',t:'MTcyNTgzNzI0Mi4wMDAwMDA='};var a=document.createElement('script');a.nonce='';a.src='/cdn-cgi/challenge-platform/scripts/jsd/main.js';document.getElementsByTagName('head')[0].appendChild(a);";b.getElementsByTagName('head')[0].appendChild(d)}}if(document.body){var a=document.createElement('iframe');a.height=1;a.width=1;a.style.position='absolute';a.style.top=0;a.style.left=0;a.style.border='none';a.style.visibility='hidden';document.body.appendChild(a);if('loading'!==document.readyState)c();else if(window.addEventListener)document.addEventListener('DOMContentLoaded',c);else{var e=document.onreadystatechange||function(){};document.onreadystatechange=function(b){e(b);'loading'!==document.readyState&&(document.onreadystatechange=e,c())}}}})();</script></body>
</html>

[[REDACTED]] [[REDACTED]] acme: error presenting token: epik: 404: <!doctype html>
<html lang="en-US" class="no-js">
<head>
    <meta charset="UTF-8">
    <title> Page not found - Epik</title>
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <link rel="icon" type="image/png" sizes="32x32"
          href="https://www.epik.com/wp-content/themes/epik-redesign/src/img/favicon.png">
    <meta name="theme-color" content="#ffffff">
    <meta name='robots' content='noindex, follow'/>
</head>
<body class="error404">
<div id="body-content" class="wrapper">
    <main class="e404-page" role="main" id="main-content">
        <div class="container-fluid">
            <div class="row">
                <div class="col-lg-6 pt-5 pb-5 text-side">
                    <div class="content-wrapper">
                        <div class="header-wrapper">
                            <h1>404 <span class="e404-header-smaller">Page not found</span></h1>
                        </div>
                        <div class="text-wrapper">
                            <p>Whoops, the link you clicked may be broken or the page may have been removed.</p>
                            <p>Return to the <a href="https://www.epik.com">homepage</a> to get back on track or <a
                                    href="/contact/">contact us</a> for assistance.</p>
                        </div>
                    </div>
                </div>
                <div class="d-none d-lg-block col-lg-6 background-side"></div>
            </div>
        </div>
    </main>
</div>
<script>(function(){function c(){var b=a.contentDocument||a.contentWindow.document;if(b){var d=b.createElement('script');d.innerHTML="window.__CF$cv$params={r:'8c02a2008c63d7a7',t:'MTcyNTgzNzI0NS4wMDAwMDA='};var a=document.createElement('script');a.nonce='';a.src='/cdn-cgi/challenge-platform/scripts/jsd/main.js';document.getElementsByTagName('head')[0].appendChild(a);";b.getElementsByTagName('head')[0].appendChild(d)}}if(document.body){var a=document.createElement('iframe');a.height=1;a.width=1;a.style.position='absolute';a.style.top=0;a.style.left=0;a.style.border='none';a.style.visibility='hidden';document.body.appendChild(a);if('loading'!==document.readyState)c();else if(window.addEventListener)document.addEventListener('DOMContentLoaded',c);else{var e=document.onreadystatechange||function(){};document.onreadystatechange=function(b){e(b);'loading'!==document.readyState&&(document.onreadystatechange=e,c())}}}})();</script></body>
</html>

Go environment (if applicable)

$ go version && go env
# paste output here
@Teuwu Teuwu added the bug label Sep 8, 2024
@ldez ldez changed the title epik returns 404 epik: returns 404 Sep 8, 2024
@ldez
Copy link
Member

ldez commented Sep 8, 2024

Hello,

I think there are some missing logs after the HTML stack.

The Epik API documentation seems down https://docs.userapi.epik.com/v2/

And the API seems down too https://usersapiv2.epik.com/v2

Maybe they have a problem, I recommend contacting Epik support.

@m-aza
Copy link

m-aza commented Oct 4, 2024

The Epik API documentation seems down https://docs.userapi.epik.com/v2/

actual URL is https://docs-userapi.epik.com/v2/
https://usersapiv2.epik.com/v2 returns 404 if User-Agent isn't set.

@ldez
Copy link
Member

ldez commented Oct 4, 2024

https://usersapiv2.epik.com/v2 returns 404 if User-Agent isn't set.

Is this documented somewhere?

@m-aza
Copy link

m-aza commented Oct 4, 2024

not I'm aware of

@ldez
Copy link
Member

ldez commented Oct 4, 2024

Do you learn that from the Epik support?

I'm looking for an official reference.

Can you try this PR #2290 ?

@m-aza
Copy link

m-aza commented Oct 4, 2024

wrong docs url was from support, user-agent issue comes from playing with API in browser and wget
as of #2290 looks like any occurrence of go- in user agent name result in 404 🤦‍♂️

@ldez
Copy link
Member

ldez commented Oct 4, 2024

I changed the user agent inside the PR.

@m-aza
Copy link

m-aza commented Oct 4, 2024

It works
2024/10/04 17:07:42 [INFO] [test....] Server responded with a certificate.
👍

@ldez ldez closed this as completed in #2290 Oct 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

Successfully merging a pull request may close this issue.

3 participants