# Error: access denied to install certbot-dns-cloudflare

**URL:** <https://community.letsencrypt.org/t/error-access-denied-to-install-certbot-dns-cloudflare/156775>\
**Category:** Help\
**Created:** [July 29, 2021, 6:44pm UTC](https://community.letsencrypt.org/t/error-access-denied-to-install-certbot-dns-cloudflare/156775 "2021-07-29T18:44:57Z")\
**Posts on this page:** 16\
**Page:** 1

<div class="post-metadata">

**Author:** ![campari](https://sea3.discourse-cdn.com/letsencrypt/user_avatar/community.letsencrypt.org/campari/32/51538_2.png) [@campari](https://community.letsencrypt.org/u/campari)\
**Post date:** [July 29, 2021, 6:44pm UTC](https://community.letsencrypt.org/t/error-access-denied-to-install-certbot-dns-cloudflare/156775/1 "2021-07-29T18:44:57Z")

</div>

Hi,  
My domain is: `irchelp.com.br` and I would like to install the dns-cloudflare plugin to automatically renew my wildcard certificate, however when I try to install the certbot-dns-cloudflare plugin running command: `sudo snap install certbot-dns-cloudflare` I get an error

> error: access denied  
> Only connect this interface if you trust the plugin author to have root on the system.  
> Run `snap set certbot trust-plugin-with-root=ok` to acknowledge this and then run this command again to perform the connection.  
> If that doesn't work, you may need to remove all certbot-dns-\* plugins from the system, then try installing the certbot snap again.

I already followed the steps of [https://certbot.eff.org/lets-encrypt/debianstretch-apache](https://certbot.eff.org/lets-encrypt/debianstretch-apache)

My web server is :  
Server version: Apache/2.4.25 (Debian)  
Server built: 2021-07-09T08:12:34

The operating system my web server runs on is:  
Debian|  
Debian GNU/Linux 9.13 (stretch)|  
Release:9.13  
Codename: stretch

My hosting provider, is: [cloudflare.com](http://cloudflare.com)

I can login to a root shell on my machine: Yes

I'm using a control panel to manage my site: No

The version of my client is: certbot 1.17.0

Thanks for you attention.

---

<div class="post-metadata">

**Author:** ![rg305](https://sea3.discourse-cdn.com/letsencrypt/user_avatar/community.letsencrypt.org/rg305/32/91314_2.png) [@rg305](https://community.letsencrypt.org/u/rg305)\
**Post date:** [July 29, 2021, 7:40pm UTC](https://community.letsencrypt.org/t/error-access-denied-to-install-certbot-dns-cloudflare/156775/2 "2021-07-29T19:40:33Z")

</div>

Hi @campari, and welcome to the LE community forum 🙂

Did you completely follow **Step #3** and **Step #4**?

Also: Without added LTS, Deb9 is past EOL.

---

<div class="post-metadata">

**Author:** ![\_az](https://avatars.discourse-cdn.com/v4/letter/_/22d042/32.png) [@\_az](https://community.letsencrypt.org/u/_az)\
**Post date:** [July 29, 2021, 8:26pm UTC](https://community.letsencrypt.org/t/error-access-denied-to-install-certbot-dns-cloudflare/156775/3 "2021-07-29T20:26:14Z")

</div>

This is unfortunately a bug that appeared recently on Debian Stretch.

We plan to have a workaround for it in time for Certbot 1.18, but until then you may need to use the pip instructions instead.

---

<div class="post-metadata">

**Author:** ![campari](https://sea3.discourse-cdn.com/letsencrypt/user_avatar/community.letsencrypt.org/campari/32/51538_2.png) [@campari](https://community.letsencrypt.org/u/campari)\
**Post date:** [July 29, 2021, 8:30pm UTC](https://community.letsencrypt.org/t/error-access-denied-to-install-certbot-dns-cloudflare/156775/4 "2021-07-29T20:30:33Z")

</div>

> [@rg305](#):
>
> Also: Without added LTS, Deb9 is past EOL.

Hi,  
Yes, i completed step #3 and #4. The output to the command `$sudo snap list` is

> Name Version Rev Tracking Publisher Notes  
> certbot 1.17.0 1280 latest/stable certbot-eff✓ classic  
> core 16-2.51.3 11420 latest/stable canonical✓ core  
> core20 20210702 1081 latest/stable canonical✓ base  
> hello-world 6.4 29 latest/stable canonical✓ -

---

<div class="post-metadata">

**Author:** ![campari](https://sea3.discourse-cdn.com/letsencrypt/user_avatar/community.letsencrypt.org/campari/32/51538_2.png) [@campari](https://community.letsencrypt.org/u/campari)\
**Post date:** [July 29, 2021, 8:38pm UTC](https://community.letsencrypt.org/t/error-access-denied-to-install-certbot-dns-cloudflare/156775/5 "2021-07-29T20:38:26Z")

</div>

> [@\_az](#):
>
> This is unfortunately a bug that appeared recently on Debian Stretch.
> 
> We plan to have a workaround for it in time for Certbot 1.18, but until then you may need to use the pip instructions instead.

Hi,  
Would you can put the link with the "pip instructions"?

Thank you for your attention

---

<div class="post-metadata">

**Author:** ![\_az](https://avatars.discourse-cdn.com/v4/letter/_/22d042/32.png) [@\_az](https://community.letsencrypt.org/u/_az)\
**Post date:** [July 29, 2021, 9:07pm UTC](https://community.letsencrypt.org/t/error-access-denied-to-install-certbot-dns-cloudflare/156775/6 "2021-07-29T21:07:29Z")

</div>

The pip instructions are [here](https://certbot.eff.org/lets-encrypt/pip-apache#wildcard).

---

<div class="post-metadata">

**Author:** ![campari](https://sea3.discourse-cdn.com/letsencrypt/user_avatar/community.letsencrypt.org/campari/32/51538_2.png) [@campari](https://community.letsencrypt.org/u/campari)\
**Post date:** [July 29, 2021, 9:10pm UTC](https://community.letsencrypt.org/t/error-access-denied-to-install-certbot-dns-cloudflare/156775/7 "2021-07-29T21:10:25Z")

</div>

Thank you.

---

<div class="post-metadata">

**Author:** ![campari](https://sea3.discourse-cdn.com/letsencrypt/user_avatar/community.letsencrypt.org/campari/32/51538_2.png) [@campari](https://community.letsencrypt.org/u/campari)\
**Post date:** [July 29, 2021, 9:35pm UTC](https://community.letsencrypt.org/t/error-access-denied-to-install-certbot-dns-cloudflare/156775/8 "2021-07-29T21:35:22Z")

</div>

Hi,  
I did all steps the pip instructions but when i run command `sudo certbot certonly --dns-cloudflare --dns-cloudflare-credentials /home/campari/certs/.token/cf-api-token.ini -d *.irchelp.com.br -d irchelp.com.br -i apache`

appear this output:

> Certbot can obtain and install HTTPS/TLS/SSL certificates. By default,  
> it will attempt to use a webserver both for obtaining and installing the  
> certificate.  
> certbot: error: unrecognized arguments: --dns-cloudflare-credentials

Do you think the best thing to do is upgrade to Debian 10 or 11?

---

<div class="post-metadata">

**Author:** ![\_az](https://avatars.discourse-cdn.com/v4/letter/_/22d042/32.png) [@\_az](https://community.letsencrypt.org/u/_az)\
**Post date:** [July 29, 2021, 9:40pm UTC](https://community.letsencrypt.org/t/error-access-denied-to-install-certbot-dns-cloudflare/156775/9 "2021-07-29T21:40:14Z")

</div>

Did you remove the Certbot snap before installing the `pip`-based one? It sounds maybe like the `certbot` in your `$PATH` is from some other installation method.

If you ran:

```
/opt/certbot/bin/pip install certbot-dns-cloudflare

```

You should see Cloudflare listed if you run:

```
/opt/certbot/bin/certbot plugins

```

and you shouldn't get that error.

Upgrading to Debian Buster is up to you, but it isn't strictly necessary to get this working.

---

<div class="post-metadata">

**Author:** ![campari](https://sea3.discourse-cdn.com/letsencrypt/user_avatar/community.letsencrypt.org/campari/32/51538_2.png) [@campari](https://community.letsencrypt.org/u/campari)\
**Post date:** [July 29, 2021, 9:49pm UTC](https://community.letsencrypt.org/t/error-access-denied-to-install-certbot-dns-cloudflare/156775/10 "2021-07-29T21:49:02Z")

</div>

> [@\_az](#):
>
> Did you remove the Certbot snap before installing the `pip` -based one? It sounds maybe like the `certbot` in your `$PATH` is from some other installation method.
> 
> If you ran:
> 
> ```nohighlight
> /opt/certbot/bin/pip install certbot-dns-cloudflare
> 
> ```
> 
> You should see Cloudflare listed if you run:
> 
> ```nohighlight
> /opt/certbot/bin/certbot plugins
> 
> ```
> 
> and you shouldn't get that error.
> 
> Upgrading to Debian Buster is up to you, but it isn't strictly necessary to get this working.

I didn't uninstall certbot snap, but when i run command `/opt/certbot/bin/certbot plugins`, i see the plugin dns-cloudflare.

> - apache  
> Description: Apache Web Server plugin  
> Interfaces: IAuthenticator, IInstaller, IPlugin  
> Entry point: apache = certbot\_apache.\_internal.entrypoint:ENTRYPOINT

> - dns-cloudflare  
> Description: Obtain certificates using a DNS TXT record (if you are using  
> Cloudflare for DNS).  
> Interfaces: IAuthenticator, IPlugin  
> Entry point: dns-cloudflare =  
> certbot\_dns\_cloudflare.\_internal.dns\_cloudflare:Authenticator

> - standalone  
> Description: Spin up a temporary webserver  
> Interfaces: IAuthenticator, IPlugin  
> Entry point: standalone = certbot.\_internal.plugins.standalone:Authenticator

> - webroot  
> Description: Place files in webroot directory  
> Interfaces: IAuthenticator, IPlugin  
> Entry point: webroot = certbot.\_internal.plugins.webroot:Authenticator

should I uninstall certbot snap?

---

<div class="post-metadata">

**Author:** ![\_az](https://avatars.discourse-cdn.com/v4/letter/_/22d042/32.png) [@\_az](https://community.letsencrypt.org/u/_az)\
**Post date:** [July 29, 2021, 9:52pm UTC](https://community.letsencrypt.org/t/error-access-denied-to-install-certbot-dns-cloudflare/156775/11 "2021-07-29T21:52:34Z")

</div>

Yeah. If you're using the `pip`-installed version of Certbot, it is a substitute for the Certbot snap.

Afterwards, don't forget the step in the instructions to then put the `pip`-installed Certbot into your `PATH`:

```
sudo ln -s /opt/certbot/bin/certbot /usr/bin/certbot
```

---

<div class="post-metadata">

**Author:** ![campari](https://sea3.discourse-cdn.com/letsencrypt/user_avatar/community.letsencrypt.org/campari/32/51538_2.png) [@campari](https://community.letsencrypt.org/u/campari)\
**Post date:** [July 29, 2021, 9:55pm UTC](https://community.letsencrypt.org/t/error-access-denied-to-install-certbot-dns-cloudflare/156775/12 "2021-07-29T21:55:51Z")

</div>

> [@\_az](#):
>
> `sudo ln -s /opt/certbot/bin/certbot /usr/bin/certbot`

Ok. I will remove everything and redo the steps.

PS.: I didi this step `sudo ln -s /opt/certbot/bin/certbot /usr/bin/certbot`.

---

<div class="post-metadata">

**Author:** ![campari](https://sea3.discourse-cdn.com/letsencrypt/user_avatar/community.letsencrypt.org/campari/32/51538_2.png) [@campari](https://community.letsencrypt.org/u/campari)\
**Post date:** [July 29, 2021, 10:10pm UTC](https://community.letsencrypt.org/t/error-access-denied-to-install-certbot-dns-cloudflare/156775/13 "2021-07-29T22:10:47Z")

</div>

Okay. It worked.

Thank you very much folks.

Best wishes.

---

<div class="post-metadata">

**Author:** ![Osiris](https://avatars.discourse-cdn.com/v4/letter/o/839c29/32.png) [@Osiris](https://community.letsencrypt.org/u/Osiris)\
**Post date:** [July 30, 2021, 5:51am UTC](https://community.letsencrypt.org/t/error-access-denied-to-install-certbot-dns-cloudflare/156775/14 "2021-07-30T05:51:06Z")

</div>

@_az It seems step 4 of the pip instructions are just refering to certbot-auto and OS installed certbot packages. Probably should include snap too.

---

<div class="post-metadata">

**Author:** ![\_az](https://avatars.discourse-cdn.com/v4/letter/_/22d042/32.png) [@\_az](https://community.letsencrypt.org/u/_az)\
**Post date:** [July 30, 2021, 6:38am UTC](https://community.letsencrypt.org/t/error-access-denied-to-install-certbot-dns-cloudflare/156775/15 "2021-07-30T06:38:13Z")

</div>

Thanks, created [a change](https://github.com/certbot/website/pull/726) for that.

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/letsencrypt/original/3X/c/a/ca6c06ea1ea201324bba7048c6841ce60236468d.png) [@system](https://community.letsencrypt.org/u/system)\
**Post date:** [August 29, 2021, 6:38am UTC](https://community.letsencrypt.org/t/error-access-denied-to-install-certbot-dns-cloudflare/156775/16 "2021-08-29T06:38:40Z")

</div>

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
