LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 06-13-2017, 04:22 PM   #1
Panicked
LQ Newbie
 
Registered: Jun 2017
Posts: 21

Rep: Reputation: Disabled
Letsencrypt certbot


Following walkthrough at https://medium.com/@silverbackdan/in...t-f412198c3051

This is a test using 'localdomain' and 'localhost'

Completed Step 6; how do I fix Step 7?

STDIN:

sudo certbot certonly --standalone -d localdomain --renew-hook "/etc/haproxy/cert-hook"

Observation: No symbolic link is created at /etc/letsencrypt/live

STDOUT:

Obtaining a new certificate
An unexpected error occurred
The request message was malformed :: Error creating new authz :: DNS name does not have enough labels

LOG (contains only benign DEBUGs):
DEBUG:certbot.plugins.selection:Requestor authenticator standalone and installer <certbot.cli._Default object at 0x25cfbd0>
 
Old 06-13-2017, 05:32 PM   #2
Panicked
LQ Newbie
 
Registered: Jun 2017
Posts: 21

Original Poster
Rep: Reputation: Disabled
Answer:

My localdomain is invalid. Certbot can only issue certificates for valid public domain names.
 
Old 06-13-2017, 05:52 PM   #3
astrogeek
Moderator
 
Registered: Oct 2008
Distribution: Slackware [64]-X.{0|1|2|37|-current} ::12<=X<=15, FreeBSD_12{.0|.1}
Posts: 6,263
Blog Entries: 24

Rep: Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194
That is correct, LetsEncrypt will only sign certificates for domains which can be found by DNS lookup.

If you are testing on your local machine you can issue your own self signed certificate.

On the other hand, if you are trying to get certbot working then you will need a "real" (i.e. registered) domain.

What is your main objective?
 
Old 06-13-2017, 05:56 PM   #4
Panicked
LQ Newbie
 
Registered: Jun 2017
Posts: 21

Original Poster
Rep: Reputation: Disabled
Objective is functional offline testing. Would like to see http fail and https succeed before exposing to the www.

I have a public domain that is inaccessible from the dev environment. How do I issue a self-signed certificate?

Last edited by Panicked; 06-13-2017 at 06:00 PM.
 
Old 06-13-2017, 06:10 PM   #5
astrogeek
Moderator
 
Registered: Oct 2008
Distribution: Slackware [64]-X.{0|1|2|37|-current} ::12<=X<=15, FreeBSD_12{.0|.1}
Posts: 6,263
Blog Entries: 24

Rep: Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194
Quote:
Originally Posted by Panicked View Post
Objective is functional offline testing. Would like to see http fail and https succeed before exposing to the www.

I have a public domain that is inaccessible from the dev environment. How do I issue a self-signed certificate?
That is still not very clear - functional offline testing of what exactly - server config, SSL/TLS methods, website code...?

How should http fail and https succeed, exactly? A better description of what you are trying to accomplish would go a long way.

In the mean time, if you just need a certificate, you can generate your own on just about any GNU/Linux platform:

Code:
openssl req -new -x509 -sha256 -days 365 -nodes -out /etc/ssl/path-to-certs/example.com.crt
    -keyout /etc/ssl/path-to-keys/example.com.key

chmod 600 /etc/ssl/path-to-{certs,keys}/example.com*
Adjust for your actual paths, then restart your web server. When you request the site the first time it will ask you to grant an exception for the self-signed cert, but it will all work as expected, assuming your server is configured correctly.
 
1 members found this post helpful.
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
LXer: Secure your webserver with improved Certbot LXer Syndicated Linux News 0 05-26-2017 10:01 AM
[SOLVED] Bundle SSL certificates with LetsEncrypt/Certbot? kikinovak Slackware 1 03-14-2017 07:58 AM
LXer: Using certbot to secure your personal site LXer Syndicated Linux News 0 02-23-2017 02:01 PM
LXer: LetsEncrypt now available in Fedora LXer Syndicated Linux News 0 12-14-2015 05:42 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 05:38 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration