Koozali.org: home of the SME Server

certificat de sécurité

Online Jean-Philippe Pialasse

  • *
  • 2,747
  • +11/-0
  • aka Unnilennium
    • http://smeserver.pialasse.com
Re: certificat de sécurité
« Reply #30 on: February 17, 2020, 01:56:17 PM »
Domains peut marcher si seulement et si tous tew domaines renseigné pointent en tous temps vers ton sme depuis l’internet. Dans le cas contraire la generation du certificat risque d'échouer. Tu peux decider par exemple dans deux semaines de rejouter un monreseau.local pour un usage particulier en interne et cela plantera ton renouvellement

La technique de garder à none est p’us sécuritaire. On peut ensuite sélectionner des domaines et hotes (sous domaines) à la piece.
« Last Edit: February 17, 2020, 02:01:30 PM by Jean-Philippe Pialasse »

Offline ecureuil

  • *
  • 261
  • +0/-0
Re: certificat de sécurité
« Reply #31 on: February 17, 2020, 02:23:59 PM »
Je n'ai qu'un domaine ;)

Mais j'ai un paquet de hosts

Ce qui me surprend c'est proxy et ftp sont dans les hosts sur sme
« Last Edit: February 17, 2020, 09:25:52 PM by ecureuil »

Offline ecureuil

  • *
  • 261
  • +0/-0
Re: certificat de sécurité
« Reply #32 on: February 18, 2020, 01:38:59 PM »
Domains peut marcher si seulement et si tous tew domaines renseigné pointent en tous temps vers ton sme depuis l’internet. Dans le cas contraire la generation du certificat risque d'échouer. Tu peux decider par exemple dans deux semaines de rejouter un monreseau.local pour un usage particulier en interne et cela plantera ton renouvellement

La technique de garder à none est p’us sécuritaire. On peut ensuite sélectionner des domaines et hotes (sous domaines) à la piece.

Je n'ai qu'un domaine

Mais beaucoup de hotsts

Comment sélectionner les hosts?

Anne

Online Jean-Philippe Pialasse

  • *
  • 2,747
  • +11/-0
  • aka Unnilennium
    • http://smeserver.pialasse.com
Re: certificat de sécurité
« Reply #33 on: February 18, 2020, 07:18:40 PM »
Meme principe tu laisse configure a none

Puis pour les domaines et les hosts qui t’interessent tu fais setprop letsencryptSSLcert enabled

db domains setprop mondomaine letsencryptSSLcert enabled

db hosts setprop monhost.mondomaine letsencryptSSLcert enabled

Offline ecureuil

  • *
  • 261
  • +0/-0
Re: certificat de sécurité
« Reply #34 on: February 19, 2020, 01:28:03 AM »
Meme principe tu laisse configure a none

Puis pour les domaines et les hosts qui t’interessent tu fais setprop letsencryptSSLcert enabled

db domains setprop mondomaine letsencryptSSLcert enabled

db hosts setprop monhost.mondomaine letsencryptSSLcert enabled

J'ai bien compris

Avec server-manager

pour domain je n'ai  qu'un domaine => facile
domain.com   Primary domain   Primary   Résolu localement

Pour hosts, j'en ai beaucoup

ftp.domain.com   Self   10.97.1.1
mail.domain.com   Self   10.97.1.1
nuts.domain.com   Local   10.97.1.80
pc-00105.domain.com   Local   10.97.1.51
proxy.domain.com   Self   10.97.1.1
tux.domain.com   Self   10.97.1.1
wpad.domain.com   Self   10.97.1.1
www.domain.com   Self   10.97.1.1
www2.domain.com   Self   10.97.1.1

pour wpad je ne sais plus d'où cela vient

j'ai trouvé cela
https://wiki.contribs.org/SME-101.04_Certificat_Let%27s_Encrypt

J'ai vérifié avec Qualsys SSLLabs
Certificate en vert
Protocol Support en orange
Key Exchange en orange
Cipher Strength en vert

pour Key Exchange c'est normal selon celui qui a fait le howto
pour Protocol Support c'est en orange ???

voilà pour mes tests

Anne

« Last Edit: February 19, 2020, 01:30:53 AM by ecureuil »

Offline ReetP

  • *
  • 3,722
  • +5/-0
Re: certificat de sécurité
« Reply #35 on: February 19, 2020, 10:27:29 AM »
If you read the manual you will find that proxy, wpad etc are created automatically on install.

They can be ignored or removed.

Amber settings. If you read down the page it tells you why (use google translate). It is probably because apache still supports older versions of TLS.

There are some answers here and in the forums about this. Have a search.

N.B The wiki page you referred to is for older versions of letsencrypt/dehydrated so be careful with the information as it may be out of date.
...
1. Read the Manual
2. Read the Wiki
3. Don't ask for support on Unsupported versions of software
4. I have a job, wife, and kids and do this in my spare time. If you want something fixed, please help.

Bugs are easier than you think: http://wiki.contribs.org/Bugzilla_Help

If you love SME and don't want to lose it, join in: http://wiki.contribs.org/Koozali_Foundation

Offline ecureuil

  • *
  • 261
  • +0/-0
Re: certificat de sécurité
« Reply #36 on: March 05, 2020, 05:52:01 PM »
bonjour,

J'ai un serveur sme qui fait serveur et passerelle. J'ai un autre serveur qui se trouve dans le réseau local qui fait serveur seulement.

J'ai mis letsencrypt sur le serveur sme qui fait serveur et passerelle.
Cela fonctionne bien.

Comment faire pour  avoir letsencrypt  pour le serveur sme  qui fait serveur seulement. et qui se trouve dans le réseau local?

J'ai regardé la contrib version française :
Sujets avancés
Obtention de certificats pour d'autres serveurs

J'installe quoi et où, pour avoir le certificat en vert avec firefox avec le serveur local.

Merci
Anne
« Last Edit: March 05, 2020, 05:53:39 PM by ecureuil »

Offline ReetP

  • *
  • 3,722
  • +5/-0
Re: certificat de sécurité
« Reply #37 on: March 05, 2020, 06:28:56 PM »
You really need to do some trial and error. It is very frustrating having to retype the entire wiki here for you.

Simply.

Create a host in your Hosts panel and set it to Local and the local IP. From the INTERNET that host will HAVE to resolve to your main SME.

Set the host letsentcryptSSLcert enabled

console-save

Make sure you can ssh/scp from your main SME to the local only SME WITHOUT passwords. Read how on the wiki please.

Either follow the wiki:
https://wiki.contribs.org/Letsencrypt#Obtaining_certificates_for_a_private_SME_Server

Or create your own hook-script template as per the wiki with your settings as per this:
https://wiki.contribs.org/Letsencrypt#Hook_Script_deployment

Code: [Select]
{
    use strict;
    use warnings;
    use esmith::ConfigDB;

    my $configDB = esmith::ConfigDB->open_ro or die("can't open Config DB");

    my $letsencryptStatus = $configDB->get_prop( 'letsencrypt', 'status' )     || 'disabled';

    if ( $letsencryptStatus ne 'disabled' ) {

    $OUT .=<<'_EOF';
if [ $1 = "deploy_cert" ] && [ $2 = "hostname.domain.tld" ]; then
  KEY=$3
  CERT=$4
  CHAIN=$6
  scp $CERT root@hostname:/etc/pki/tls/certs/pbx.familybrown.org.crt
  scp $KEY root@hostname:/etc/pki/tls/private/pbx.familybrown.org.key
  scp $CHAIN root@hostname:/etc/pki/tls/certs/server-chain.crt
  ssh root@pbx "/sbin/service httpd reload"
  echo "$2 certificate renewed" | mail -s "Certificate renewal" admin@domain.tld
  exit 0
fi
_EOF

    }
}

Run dehydrated - I suggest plenty of test mode.

You may need to read both the French AND English SEVERAL times before you understand it.
...
1. Read the Manual
2. Read the Wiki
3. Don't ask for support on Unsupported versions of software
4. I have a job, wife, and kids and do this in my spare time. If you want something fixed, please help.

Bugs are easier than you think: http://wiki.contribs.org/Bugzilla_Help

If you love SME and don't want to lose it, join in: http://wiki.contribs.org/Koozali_Foundation

Offline ecureuil

  • *
  • 261
  • +0/-0
Re: certificat de sécurité
« Reply #38 on: March 06, 2020, 02:34:42 AM »
You really need to do some trial and error. It is very frustrating having to retype the entire wiki here for you.

Simply.

Create a host in your Hosts panel and set it to Local and the local IP. From the INTERNET that host will HAVE to resolve to your main SME.

Set the host letsentcryptSSLcert enabled

console-save

Make sure you can ssh/scp from your main SME to the local only SME WITHOUT passwords. Read how on the wiki please.

Tout cela c'est ok
J'ai un vpn dessus pour pouvoir y accéder à distance.

Pour la suite je regarde après dodo

C'est la suite où je me demandais si  il fallait suivre :
Obtention de certificats pour d'autres serveurs
ou
Obtenir des certificats pour un serveur KOOZALI SME privé

Si j'ai bien compris les 2 sont possibles

Anne
« Last Edit: March 06, 2020, 02:03:55 PM by ecureuil »

Offline ReetP

  • *
  • 3,722
  • +5/-0
Re: certificat de sécurité
« Reply #39 on: March 06, 2020, 02:56:49 PM »
J'ai un vpn dessus pour pouvoir y accéder à distance.

I hope it isn't PPTP....

Quote
C'est la suite où je me demandais si  il fallait suivre :
Obtention de certificats pour d'autres serveurs
ou
Obtenir des certificats pour un serveur KOOZALI SME privé

Si j'ai bien compris les 2 sont possibles

So is your other server a Koozali Private server?

"Comment faire pour  avoir letsencrypt  pour le serveur sme "

Please think about it.

The method for 'other servers' will work (because Koozali can also be a 'other server') but it was designed to be for more complicated setups.

...
1. Read the Manual
2. Read the Wiki
3. Don't ask for support on Unsupported versions of software
4. I have a job, wife, and kids and do this in my spare time. If you want something fixed, please help.

Bugs are easier than you think: http://wiki.contribs.org/Bugzilla_Help

If you love SME and don't want to lose it, join in: http://wiki.contribs.org/Koozali_Foundation

Offline ecureuil

  • *
  • 261
  • +0/-0
Re: certificat de sécurité
« Reply #40 on: March 06, 2020, 03:37:22 PM »
I hope it isn't PPTP....

pas de pptp

Paramètres PPTP
Vous pouvez autoriser l'accès VPN par PPTP à votre serveur. Nous vous recommandons de laisser cette fonctionnalité désactivée en fixant la valeur à 0, à moins que vous n'ayez absolument besoin d'un accès par PPTP.
Nombre de connexions simultanées    => 0

Quote
So is your other server a Koozali Private server?

"Comment faire pour  avoir letsencrypt  pour le serveur sme "

Please think about it.

The method for 'other servers' will work (because Koozali can also be a 'other server') but it was designed to be for more complicated setups.

Cela me parait bien plus compliqué.
Si les conditions sont requises, je préfère la solution : serveur privé
;)

sur le serveur privé
# config show modSSL
modSSL=service
    TCPPort=443
    access=public
    status=enabled

(J'ai vu que Gieres est très réactif pour la version française de  letsencrypt  Merci)
« Last Edit: March 06, 2020, 03:48:38 PM by ecureuil »

Offline ReetP

  • *
  • 3,722
  • +5/-0
Re: certificat de sécurité
« Reply #41 on: March 06, 2020, 04:12:59 PM »
PPTP - is very bad.

Use ipsec/openvpn

Code: [Select]
Si les conditions sont requises, je préfère la solution : serveur privé

Well, only you know if you have a single private SME server..... if you have then there is a simple solution for you....

ModSSL is irrelevant right now.

I have told you above what you need to do. Please read it again.

Yuo must fix this FIRST so that the servers can talk uninterrupted.

"Make sure you can ssh/scp from your main SME to the local only SME WITHOUT passwords. Read how on the wiki please."

Follow the wiki.
...
1. Read the Manual
2. Read the Wiki
3. Don't ask for support on Unsupported versions of software
4. I have a job, wife, and kids and do this in my spare time. If you want something fixed, please help.

Bugs are easier than you think: http://wiki.contribs.org/Bugzilla_Help

If you love SME and don't want to lose it, join in: http://wiki.contribs.org/Koozali_Foundation

Offline ecureuil

  • *
  • 261
  • +0/-0
Re: certificat de sécurité
« Reply #42 on: March 06, 2020, 04:43:16 PM »

I have told you above what you need to do. Please read it again.

Yuo must fix this FIRST so that the servers can talk uninterrupted.

Comment voir et faire?
Je ne comprends pas?
Que dois-je faire en premier?

Quote
"Make sure you can ssh/scp from your main SME to the local only SME WITHOUT passwords. Read how on the wiki please."

Comment voir si c'est ok ou pas?

Anne

Offline ReetP

  • *
  • 3,722
  • +5/-0
Re: certificat de sécurité
« Reply #43 on: March 06, 2020, 04:58:33 PM »
Comment voir et faire?
Je ne comprends pas?
Que dois-je faire en premier?

Please, I have not got the time to walk you you through every little detail. This is basic linux ssh usage.  There are thousands of pages out there. Look for ssh login with keys, not passwords.

e.g.
https://www.thegeekdiary.com/centos-rhel-how-to-setup-passwordless-ssh-login/

If you cannot transfer files without a password then you cannot transfer a certificate without a password. So do this first.

Quote
Comment voir si c'est ok ou pas?

Like this:
Quote
Make sure you can ssh/scp from your main SME to the local only SME WITHOUT passwords

Can you login from your main server to your private only server without a password?

You have GOT to try and do some of this yourself.

Just give it a go. Try it. You might learn something by breaking things, which is how WE learned.

You are NOT reading enough and not trying enough.

Once you have tried doing some of this and it breaks then come back and ask. But I can't help you unless you have started to do some work yourself.

This forum is for help when you get stuck. It is not here to tell you in tiny little steps how to do it. You are meant to try and do things by yourself. If you don't you are just going to get ignored.
...
1. Read the Manual
2. Read the Wiki
3. Don't ask for support on Unsupported versions of software
4. I have a job, wife, and kids and do this in my spare time. If you want something fixed, please help.

Bugs are easier than you think: http://wiki.contribs.org/Bugzilla_Help

If you love SME and don't want to lose it, join in: http://wiki.contribs.org/Koozali_Foundation

Offline ecureuil

  • *
  • 261
  • +0/-0
Re: certificat de sécurité
« Reply #44 on: March 07, 2020, 01:11:15 AM »
https://www.thegeekdiary.com/centos-rhel-how-to-setup-passwordless-ssh-login/

Generate authentication key
If an SSH authentication-key file does not exist, generate one by running the ssh-keygen command. When prompted for a passphrase, use a blank passphrase if fully password-less login is required:

Générer une clé d'authentification
Si un fichier de clé d'authentification SSH n'existe pas, générez-le en exécutant la commande ssh-keygen. Lorsque vous êtes invité à saisir une phrase secrète, utilisez une phrase secrète vierge si une connexion sans mot de passe est requise:


J'ai fait la commande mais en étant root.
Je n'ai pas d’utilisateur sur ce serveur à part faxadmin root et admin.


Copy the public key to remote host
Use the ssh-copy-id command to install the public half of the newly-generated authentication key into a specific user’s home directory on the remote host. The ssh-copy-id command will then automatically append the identity information into the ~/.ssh/authorized_keys file for the specified user on the remote host (creating ~/.ssh and~/.ssh/authorized_keys if necessary).

Copiez la clé publique sur l'hôte distant
Utilisez la commande ssh-copy-id pour installer la moitié publique de la clé d'authentification nouvellement générée dans le répertoire de base d'un utilisateur spécifique sur l'hôte distant. La commande ssh-copy-id ajoutera alors automatiquement les informations d'identité dans le fichier ~/.ssh/authorized_keys pour l'utilisateur spécifié sur l'hôte distant (en créant ~/.ssh and~/.ssh/authorized_keys si nécessaire).

Je fais comment?
Anne