Impossible de configurer https avec letsencrypt

Edit
La MAJ des DNS a eu lieu.
J’ai bien accès à mon serveur via http://maison.bebelcyl.fr ou http://bebelcyl.fr.

Mais toujours le mm soucis de Error getting validation data

Je note qu’il renvoi automatiquement le http vers le https (avec erreur de sécurité), il n’y aurait pas un réglage sur le serveur pour rester en http pour le moment ?

non
mais tu a refait ta procédure sur
le sous domaine ?

quand je vais sur ton site on vois bien qu’il n’y a pas de certificat …

oui j’ai fait un certbot -apache avec le sous domaine et même le domaine …

root@jeedom:/home/jeedom# certbot --apache
Saving debug log to /var/log/letsencrypt/letsencrypt.log
Plugins selected: Authenticator apache, Installer apache
No names were found in your configuration files. Please enter in your domain
name(s) (comma and/or space separated) (Enter ‹ c › to cancel): bebelcyl.fr
Obtaining a new certificate
Performing the following challenges:
http-01 challenge for bebelcyl.fr
Enabled Apache rewrite module
Waiting for verification…
Cleaning up challenges
Failed authorization procedure. bebelcyl.fr (http-01): urn:ietf:params:acme:error:connection :: The server could not connect to the client to verify the domain :: Fetching http://bebelcyl.fr/.well-known/acme-challenge/eQQKY1Cfnhzb8fGLYK3wPF6rsv2bnEhvR_6o1mnx1g4: Error getting validation data

IMPORTANT NOTES:

  • The following errors were reported by the server:

    Domain: bebelcyl.fr
    Type: connection
    Detail: Fetching
    http://bebelcyl.fr/.well-known/acme-challenge/eQQKY1Cfnhzb8fGLYK3wPF6rsv2bnEhvR_6o1mnx1g4:
    Error getting validation data

    To fix these errors, please make sure that your domain name was
    entered correctly and the DNS A/AAAA record(s) for that domain
    contain(s) the right IP address. Additionally, please check that
    your computer has a publicly routable IP address and that no
    firewalls are preventing the server from communicating with the
    client. If you’re using the webroot plugin, you should also verify
    that you are serving files from the webroot path you provided.
    root@jeedom:/home/jeedom# certbot --apache
    Saving debug log to /var/log/letsencrypt/letsencrypt.log
    Plugins selected: Authenticator apache, Installer apache
    No names were found in your configuration files. Please enter in your domain
    name(s) (comma and/or space separated) (Enter ‹ c › to cancel): maison.bebelcyl.fr
    Obtaining a new certificate
    Performing the following challenges:
    http-01 challenge for maison.bebelcyl.fr
    Enabled Apache rewrite module
    Waiting for verification…
    Cleaning up challenges
    Failed authorization procedure. maison.bebelcyl.fr (http-01): urn:ietf:params:acme:error:connection :: The server could not connect to the client to verify the domain :: Fetching http://maison.bebelcyl.fr/.well-known/acme-challenge/hjvj2iOjynXGDYdAepDclkFKku7izkoE4uBufqf5aGU: Error getting validation data

IMPORTANT NOTES:

  • The following errors were reported by the server:

    Domain: maison.bebelcyl.fr
    Type: connection
    Detail: Fetching
    http://maison.bebelcyl.fr/.well-known/acme-challenge/hjvj2iOjynXGDYdAepDclkFKku7izkoE4uBufqf5aGU:
    Error getting validation data

    To fix these errors, please make sure that your domain name was
    entered correctly and the DNS A/AAAA record(s) for that domain
    contain(s) the right IP address. Additionally, please check that
    your computer has a publicly routable IP address and that no
    firewalls are preventing the server from communicating with the
    client. If you’re using the webroot plugin, you should also verify
    that you are serving files from the webroot path you provided.
    root@jeedom:/home/jeedom#

refait ta procédure avec que maison.bebelcyl.fr
comme dans l’exemple

si tu a bien le " congratulation " comme ci-dessous

image

Merci de prendre le temps de m’aiguiller.
Je dois désinstaller qqch avant ?

Non mais si tu fait trop de demande tu va te faire ban un certain temps !

Toujours la mm erreur

root@jeedom:/home/jeedom# certbot --apache
Saving debug log to /var/log/letsencrypt/letsencrypt.log
Plugins selected: Authenticator apache, Installer apache
No names were found in your configuration files. Please enter in your domain
name(s) (comma and/or space separated) (Enter ‹ c › to cancel): bebelcyl.fr Obtaining a new certificate
Performing the following challenges:
http-01 challenge for bebelcyl.fr
Enabled Apache rewrite module
Waiting for verification…
Cleaning up challenges
Failed authorization procedure. bebelcyl.fr (http-01): urn:ietf:params:acme:erro r:connection :: The server could not connect to the client to verify the domain :: Fetching http://bebelcyl.fr/.well-known/acme-challenge/ba_A9ymVjNsCpQe-CX6reW sXkiDRr32KGvYV_dxT1gs: Error getting validation data

IMPORTANT NOTES:

Voici le log du fichier

root@jeedom:/var/log/letsencrypt# tail letsencrypt.log
orderr = self._get_order_and_authorizations(csr.data, self.config.allow_subs et_of_names)
File « /usr/lib/python3/dist-packages/certbot/client.py », line 389, in _get_ord er_and_authorizations
authzr = self.auth_handler.handle_authorizations(orderr, best_effort)
File « /usr/lib/python3/dist-packages/certbot/auth_handler.py », line 82, in han dle_authorizations
self._respond(aauthzrs, resp, best_effort)
File « /usr/lib/python3/dist-packages/certbot/auth_handler.py », line 168, in _r espond
self._poll_challenges(aauthzrs, chall_update, best_effort)
File « /usr/lib/python3/dist-packages/certbot/auth_handler.py », line 239, in _p oll_challenges
raise errors.FailedChallenges(all_failed_achalls)
certbot.errors.FailedChallenges: Failed authorization procedure. bebelcyl.fr (ht tp-01): urn:ietf:params:acme:error:connection :: The server could not connect to the client to verify the domain :: Fetching http://bebelcyl.fr/.well-known/acme -challenge/ba_A9ymVjNsCpQe-CX6reWsXkiDRr32KGvYV_dxT1gs: Error getting validation data

tu a pas mis
maison.bebelcyl.fr

Je viens de repartir sur une image propre de jeedom (celle du site), j’ai mis à jour les paquets, restaurer ma sauvegarde jeedom.
La console jeedom est bien accessible depuis http://maison.bebelcyl.fr.

J’ai à nouveau suivi la procédure sur youdom, j’ai à nouveau le même souci…

root@jeedom:/home/jeedom# certbot --apache
Saving debug log to /var/log/letsencrypt/letsencrypt.log
Plugins selected: Authenticator apache, Installer apache
Enter email address (used for urgent renewal and security notices) (Enter ‹ c › to
cancel): xxx


Please read the Terms of Service at
https://letsencrypt.org/documents/LE-SA-v1.2-November-15-2017.pdf. You must
agree in order to register with the ACME server at
https://acme-v02.api.letsencrypt.org/directory


(A)gree/(C)ancel: a


Would you be willing to share your email address with the Electronic Frontier
Foundation, a founding partner of the Let’s Encrypt project and the non-profit
organization that develops Certbot? We’d like to send you email about our work
encrypting the web, EFF news, campaigns, and ways to support digital freedom.


(Y)es/(N)o: n
No names were found in your configuration files. Please enter in your domain
name(s) (comma and/or space separated) (Enter ‹ c › to cancel): maison.bebelcyl.fr
Obtaining a new certificate
Performing the following challenges:
http-01 challenge for maison.bebelcyl.fr
Enabled Apache rewrite module
Waiting for verification…
Cleaning up challenges
Failed authorization procedure. maison.bebelcyl.fr (http-01): urn:ietf:params:acme:error:connection :: The server could not connect to the client to verify the domain :: Fetching http://maison.bebelcyl.fr/.well-known/acme-challenge/mJReeVxtyc3bo_3vJs7V3wN5BnC74cwOsakqpN3jNRM: Error getting validation data

IMPORTANT NOTES:

  • The following errors were reported by the server:

    Domain: maison.bebelcyl.fr
    Type: connection
    Detail: Fetching
    http://maison.bebelcyl.fr/.well-known/acme-challenge/mJReeVxtyc3bo_3vJs7V3wN5BnC74cwOsakqpN3jNRM:
    Error getting validation data

    To fix these errors, please make sure that your domain name was
    entered correctly and the DNS A/AAAA record(s) for that domain
    contain(s) the right IP address. Additionally, please check that
    your computer has a publicly routable IP address and that no
    firewalls are preventing the server from communicating with the
    client. If you’re using the webroot plugin, you should also verify
    that you are serving files from the webroot path you provided.

  • Your account credentials have been saved in your Certbot
    configuration directory at /etc/letsencrypt. You should make a
    secure backup of this folder now. This configuration directory will
    also contain certificates and private keys obtained by Certbot so
    making regular backups of this folder is ideal.

Je pense qu’il y a un problème d’accès depuis l’extérieur (hors réseau local) à ton installation.
Il est pour ma part impossible d’accéder par chrome à l’URL suivante : http://maison.bebelcyl.fr/

Ceci explique pourquoi letsencrypt n’arrive pas à valider le certificat

Bonjour,

effectivement je tester avec mon téléphone en 4G mais il a du conserver l’historique…

Voici ma config ionos (changer cet aprem)

Je pense que tu peux supprimer l’enregistrement AAAA (maison) qui correspond à une adresse IPV6. Peu de chance que ton infrastructure de ton réseau local soit full IPV6 :wink:

Au de la définition de tes DNS, je pense plutôt à un problème de configuration de ton réseau interne (routeur) pour rediriger le port 80 (et bien sur 443 une fois ton certificat validé) vers l’adresse IP de la machine qui héberge ton jeedom.
Suite à ta réinstallation, es-tu sur à 100% que l’adresse IP jest toujours celle que tu avais défini dans la configuration de ton routeur pour la redirection du port ?

1 « J'aime »

Bonjour, merci de prendre le temps de m’aider
Je viens de tester plusieurs trucs :

La redirection via le nom de domaine maison.bebelcyl.fr est bien actif sur mon ip : 82.64.176.133 (tester avec mes caméras et accès sur la freebox ou mon nas).
En local, j’ai bien accès à mon raspberry qui est sur 192.168.1.44 (en http ou https)
Qd je teste depuis l’extérieur sur https://82.64.176.133:443 ou https://maison.bebelcyl.fr je tombe bien sur mon serveur (redirection port ok) -avec abs de certificat
Par contre, cela ne fonctionne pas en http. Je précise que le port 80 et bien redirigé vers le 80 du raspberry

Je pense donc que le souci vient du raspberry. Mes connaissances sont assez limités pour savoir où aller chercher… C’est étonnant que je puisse m’y connecter sur le port 80 en local mais pas en distanciel (j’ai regardé, apache écoute bien le port 80).

Une idée ?

Tu as déjà un certificat qui est activé en https sur ton installation jeedom mais ce n’est pas un certificat officiel.

Par contre, il est toujours impossible de me connecter à ton serveur sur le port 80 ce qui empêche logiquement letsencrypt de valider le challenge et générer un certificat valide.
Je pense que tu devrais repartir sur une installation from scratch et vérifier avant toute chose que tu peux accéder à jeedom sur le port 80.
Une fois ceci fait, il suffit normalement d’installer les packages certbot et python-certbot-apache pour installer le certificat…

Edit :
J’ai supprimé les redirections de port sur la freebox pour les recreer… ça marche. J’ai pu valider le certificat en 2 temps 3 mouvements.
Merci à tous pour le temps pris pour m’aider. @thanaus @olive @Bison

C’est pas bon du tout ta config
commence par supprimer toute les lignes
pour ne garder que

    A    @          82.64.176.133
CNAME    maison     bebelcyl.fr

Je n’ai pas spécialement envie que bebelcyl.fr renvoie sur mon serveur… d’où le renvoi du sous-domaine

En attendant ça arrive quand même dessus pour l’instant voir image ci-dessous
le cname maison sert a renvoyer
maison.bebelcyl.fr
sur ta box …

Curieux bug, bien joué :+1:

Ce sujet a été automatiquement fermé après 24 heures suivant le dernier commentaire. Aucune réponse n’est permise dorénavant.