tag:blogger.com,1999:blog-7409597408023081712.post3092784450225400286..comments2026-04-07T14:50:10.010+02:00Comments on Random Thoughts on Java Programming: Enabling SSL in Glassfish with certificate from Let's Encrypt.Turbohttp://www.blogger.com/profile/05959847299811800007noreply@blogger.comBlogger2125tag:blogger.com,1999:blog-7409597408023081712.post-79250383966099072572020-09-23T15:08:23.414+02:002020-09-23T15:08:23.414+02:00That looks pretty impressive!That looks pretty impressive!Turbohttps://www.blogger.com/profile/05959847299811800007noreply@blogger.comtag:blogger.com,1999:blog-7409597408023081712.post-68083992170322525672020-05-25T03:00:42.385+02:002020-05-25T03:00:42.385+02:00I have created a Perl script to automate this proc...I have created a Perl script to automate this process. From README.md:<br /><br /># letsencrypt_glassfish<br />A script to simplify the installation and maintenance of Let's Eencrypt certificates in Glassfish and Payara web servers.<br /><br />This script is intended to simplify the installation of a Let's Encrypt certificate in a glassfish/payara server and provide an automated way of renewing that certificate when it is about to expire.<br /><br />There exists a significant amount of documentation on the web which addresses this problem but I have found much of it to be ambiguous and incomplete. This is an attempt to remove that ambiguity and incompleteness by giving a real world working example which can be modified to suit a particular situation.<br /><br />What I've done is broken the process of obtaining a Let's Encrypt certificate into the following steps, not all of which will be necessary:<br /><br />1. Customize the script to the particular local installation<br /> 1. List of domains for which a certificate is to be created<br /> 1. Glassfish/Payara setup (where they're located in your filesystem)<br /> 1. Password for Glassfish/Payara<br />1. Change Glassfish/Payara to listen on ports 80 and 443<br />1. Generate the Let's Encrypt certification keys<br />1. Insure that the keystore password matches that of the server<br />1. Create a keystore<br />1. Import the created keystore into the Glassfish/Payara keystore<br />1. Apply the new certificate to the https listener<br />1. Update the domain SSL information<br />1. Set (if necessary) the server admin password.<br />1. Set up the https domain<br /><br />Additionally, the script can be invoked periodically (typically via 'cron') to check to see if any domains need to be renewed and if so, renew them automatically.<br /><br />I have used this script to create a new certificate for three domains in less than 5 minutes. I have used this script to automatically renew three domains via a cron job.<br /><br />https://github.com/hbrednek/letsencrypt_glassfishhbrednekhttps://www.blogger.com/profile/11321594875463767590noreply@blogger.com