- SSL Certification and Key size: https://in.mathworks.com/matlabcentral/answers/597772-matlab-webapp-server-ssl-digital-certificate-key-size?s_tid=srchtitle
- HTTPS proxy URL workaround: https://in.mathworks.com/matlabcentral/answers/2076446-can-i-use-an-https-proxy-url-with-web-app-server-without-enabling-ssl?s_tid=srchtitle
- Permissions for SSL certificate and use with MATLAB Web App Server: https://in.mathworks.com/matlabcentral/answers/1933620-what-are-the-minimum-permissions-required-for-certificate-and-private-key-files-when-using-ssl-with?s_tid=srchtitle
- Support on Red Hat Enterprise Linux (RHEL): https://in.mathworks.com/matlabcentral/answers/391310-why-do-i-get-the-error-download-process-failed-problem-with-the-ssl-ca-cert-while-installing-web?s_tid=srchtitle
- Generate a self-signed certificate for testing HTTPS: https://in.mathworks.com/matlabcentral/answers/1466571-how-do-i-generate-a-self-signed-certificate-for-testing-https-functionality-in-matlab-web-app-server?s_tid=srchtitle
The server restarts constantly upon activating the "Use Secure Connection (SSL)" option.
7 views (last 30 days)
Show older comments
The Matlab App Server operates perfectly, but within a few seconds of activating the "Use Secure Connection (SSL)" option, Windows encounters an error and displays the following message: "You are about to be logged off. Windows will shut down in less than a minute." The server restarts every couple of minutes until I disable the "Use Secure Connection" option.
The certificates are properly configured, as I have tested them on another computer without encountering this issue.
Any insights into why this might be happening? I have checked the Windows error logs, but I haven't found anything that helps me resolve this problem.
Thank you in advance for your contributions.
0 Comments
Answers (1)
Sanchari
on 16 Feb 2024
Hello Jhon,
I understand that you are facing issues with MATLAB Web App Server when enabling the SSL option. However, SSL is required for Web App Server authentication to work. You can consider the following steps to troubleshoot through and resolve this issue:
1. Check all requirements: Ensure you have a MathWorks account, Web App Server license, access to SSL certificates, and an active account with the Cloud Service Provider.
2. Ensure certificate format: The certificate and private key used for enabling SSL authentication needs to be in PEM format. (The files do not need to be prefixed with “.PEM”, the contents simply needed to be PEM encoded.) Also, the key must be an RSA key up to 2048 bits in size. You can do so by typing the following command to:
a. Check a private key file: openssl rsa -in keyFileName.pem -check
b. Check a certificate file: openssl x509 -in certificateFileName.pem -text -noout
3. Generate certificate and key again: If they are not correct, you can use below openssl (https://www.openssl.org/docs/manmaster/man1/openssl.html) command to create self-signed certificate and key files. Ensure the output files will be named key.pem and cert.pem. Please refer to these man pages for meaning of each parameter, https://linux.die.net/man/1/reqhttps://linux.die.net/man/5/x509v3_config
3. Update Software: Consider updating MATLAB Web App Server to the latest release version R2023b as most bugs from previous releases have been fixed here.
4. Workaround if not wanting to update MATLAB: You can try to modify file server.js.
a. Identify file, <MWAS installation>\toolbox\compiler\mdwas\webapps_auth_oidc\server.js
b. Find line of code, postExtAuthReady (address.port); (line 299 for R2022b release).
c. Replace the line with below and then restart the server.
setTimeout (function ()
{ postExtAuthReady(address.port);
}, 10000);
5. Use HTTPS proxy URL: A workaround you can try is to use HTTPS proxy URL without enabling SSL. However, this is not a recommended workflow as it can cause WebSockets errors and performance degradation. Ensure that SSL is enabled on your Web App Server prior to configuring an HTTPS-based reverse proxy. Refer to the following documentation for instructions.
Please refer to the following ML Answers for further information on:
I hope this resolves your query!
0 Comments
See Also
Categories
Find more on Web Apps in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!