# PfSense : ajouter et configurer un VPN-SSL avec OpenVPN

Pour commencer nous allons créer une autorité de certification

Sur PfSense   
System -&gt; Certificates

[![Capture d’écran 2024-12-17 à 11.32.34.png](https://book.techoops.fr/uploads/images/gallery/2024-12/scaled-1680-/capture-decran-2024-12-17-a-11-32-34.png)](https://book.techoops.fr/uploads/images/gallery/2024-12/capture-decran-2024-12-17-a-11-32-34.png)

On va créer notre Authorites -&gt; cliquer sur "Add"

[![Capture d’écran 2024-12-17 à 11.33.18.png](https://book.techoops.fr/uploads/images/gallery/2024-12/scaled-1680-/capture-decran-2024-12-17-a-11-33-18.png)](https://book.techoops.fr/uploads/images/gallery/2024-12/capture-decran-2024-12-17-a-11-33-18.png)

On devra renseigner :  
-&gt; Le descriptive name  
-&gt; Et le pays + ville

[![Capture d’écran 2024-12-17 à 11.36.55.png](https://book.techoops.fr/uploads/images/gallery/2024-12/scaled-1680-/capture-decran-2024-12-17-a-11-36-55.png)](https://book.techoops.fr/uploads/images/gallery/2024-12/capture-decran-2024-12-17-a-11-36-55.png)

[![Capture d’écran 2024-12-17 à 11.37.13.png](https://book.techoops.fr/uploads/images/gallery/2024-12/scaled-1680-/capture-decran-2024-12-17-a-11-37-13.png)](https://book.techoops.fr/uploads/images/gallery/2024-12/capture-decran-2024-12-17-a-11-37-13.png)

[![Capture d’écran 2024-12-17 à 11.38.08.png](https://book.techoops.fr/uploads/images/gallery/2024-12/scaled-1680-/capture-decran-2024-12-17-a-11-38-08.png)](https://book.techoops.fr/uploads/images/gallery/2024-12/capture-decran-2024-12-17-a-11-38-08.png)  
On "Save"

[![Capture d’écran 2024-12-17 à 11.43.53.png](https://book.techoops.fr/uploads/images/gallery/2024-12/scaled-1680-/capture-decran-2024-12-17-a-11-43-53.png)](https://book.techoops.fr/uploads/images/gallery/2024-12/capture-decran-2024-12-17-a-11-43-53.png)  
Vous devriez avoir un certificat créée.

Ensuite, on va créer le certificat de serveur que l'ont va signer avec notre Authorites.

[![Capture d’écran 2024-12-17 à 11.45.50.png](https://book.techoops.fr/uploads/images/gallery/2024-12/scaled-1680-/capture-decran-2024-12-17-a-11-45-50.png)](https://book.techoops.fr/uploads/images/gallery/2024-12/capture-decran-2024-12-17-a-11-45-50.png)  
Cliquer sur "Add/Sign"

[![Capture d’écran 2024-12-17 à 11.49.30.png](https://book.techoops.fr/uploads/images/gallery/2024-12/scaled-1680-/capture-decran-2024-12-17-a-11-49-30.png)](https://book.techoops.fr/uploads/images/gallery/2024-12/capture-decran-2024-12-17-a-11-49-30.png)  
On renseigne :  
-&gt; Le description name  
-&gt; Le certificat d'autorité sera celui que l'ont vient de créer (il s'add automatiquement "normalement")  
-&gt; Le common name (CN)   
-&gt; On renseigne encore pays + ville

[![Capture d’écran 2024-12-17 à 11.51.54.png](https://book.techoops.fr/uploads/images/gallery/2024-12/scaled-1680-/capture-decran-2024-12-17-a-11-51-54.png)](https://book.techoops.fr/uploads/images/gallery/2024-12/capture-decran-2024-12-17-a-11-51-54.png)

Pour finir :  
-&gt; Le type de certificat -&gt; server certificate   
-&gt; Alternative name -&gt; FQDN or Hostname   
-&gt; Type -&gt; megaproduction.local

[![Capture d’écran 2024-12-17 à 11.53.14.png](https://book.techoops.fr/uploads/images/gallery/2024-12/scaled-1680-/capture-decran-2024-12-17-a-11-53-14.png)](https://book.techoops.fr/uploads/images/gallery/2024-12/capture-decran-2024-12-17-a-11-53-14.png)  
  
Le certificat devrait apparaitre comme ceci :

[![Capture d’écran 2024-12-17 à 11.56.28.png](https://book.techoops.fr/uploads/images/gallery/2024-12/scaled-1680-/capture-decran-2024-12-17-a-11-56-28.png)](https://book.techoops.fr/uploads/images/gallery/2024-12/capture-decran-2024-12-17-a-11-56-28.png)

Maintenant on va pouvoir créer un certificat utilisateur :

[![Capture d’écran 2024-12-17 à 11.45.50.png](https://book.techoops.fr/uploads/images/gallery/2024-12/scaled-1680-/capture-decran-2024-12-17-a-11-45-50.png)](https://book.techoops.fr/uploads/images/gallery/2024-12/capture-decran-2024-12-17-a-11-45-50.png)

On clique sur "Add/Sign"  
  
Comme pour le certificat serveur, on doit renseigner quelques infos :  
-&gt; Descriptive name "ADMIN-LDAP"  
-&gt; Le certificat d'autorité sera celui que l'ont vient de créer (il s'add automatiquement "normalement")  
-&gt; Common Name (CN) "megaproduction.local"  
-&gt; Pays + Ville

[![Capture d’écran 2024-12-17 à 12.03.29.png](https://book.techoops.fr/uploads/images/gallery/2024-12/scaled-1680-/capture-decran-2024-12-17-a-12-03-29.png)](https://book.techoops.fr/uploads/images/gallery/2024-12/capture-decran-2024-12-17-a-12-03-29.png)

[![Capture d’écran 2024-12-17 à 12.01.01.png](https://book.techoops.fr/uploads/images/gallery/2024-12/scaled-1680-/capture-decran-2024-12-17-a-12-01-01.png)](https://book.techoops.fr/uploads/images/gallery/2024-12/capture-decran-2024-12-17-a-12-01-01.png)  
Pour finir :  
-&gt; Le type de certificat -&gt; user certificate   
-&gt; Alternative name -&gt; FQDN or Hostname   
-&gt; Type -&gt; megaproduction.local

[![Capture d’écran 2024-12-17 à 12.01.29.png](https://book.techoops.fr/uploads/images/gallery/2024-12/scaled-1680-/capture-decran-2024-12-17-a-12-01-29.png)](https://book.techoops.fr/uploads/images/gallery/2024-12/capture-decran-2024-12-17-a-12-01-29.png)  
  
Voici le certificat utilisateur :

[![Capture d’écran 2024-12-17 à 12.16.19.png](https://book.techoops.fr/uploads/images/gallery/2024-12/scaled-1680-/capture-decran-2024-12-17-a-12-16-19.png)](https://book.techoops.fr/uploads/images/gallery/2024-12/capture-decran-2024-12-17-a-12-16-19.png)  
  
Il nous reste plus qu'à configurer OpenVPN.