snappass icon indicating copy to clipboard operation
snappass copied to clipboard

Official method of securing this with HTTPS?

Open azaloum90 opened this issue 4 years ago • 2 comments

Instructions for securing this with HTTPS are rather scarce. Any information on this?

Thanks! Adam

azaloum90 avatar Jan 12 '21 21:01 azaloum90

There is no official method for doing this, but I found this article that summarizes some of the approaches for running a Flask-based Python application over HTTPS: https://zhangtemplar.github.io/flask/

In our environment, we run it a traffic proxy (e.g. Envoy, nginx) that performs TLS termination.

jparise avatar Jan 12 '21 22:01 jparise

Here my config .conf

ServerTokens Prod ServerSignature Off Listen 1x.xxx.xxx:443 <VirtualHost 1x.xxx.xxx:443> ServerName example.net Header always set Strict-Transport-Security "max-age=31536000; includeSubDomains" Options -Indexes ProxyPreserveHost On ProxyRequests off SSLProxyEngine on SSLProxyVerify none SSLProxyCheckPeerName off SSLProxyCheckPeerCN off SSLProxyCheckPeerExpire off SSLEngine On SSLProtocol all -SSLv3 -TLSv1 -TLSv1.1 SSLCipherSuite 'ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-CHACHA20-POLY1305:ECDHE-RSA-CHACHA20-POLY1305:ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES256-SHA384:ECDHE-RSA-AES256-SHA384:ECDHE-ECDSA-AES128-SHA256:ECDHE-RSA-AES128-SHA256' SSLHonorCipherOrder on SSLCompression off SSLSessionTickets off Loglevel debug # Set the path to SSL certificate # Usage: SSLCertificateFile /path/to/cert.pem SSLCertificateFile /etc/ssl/crt.crt SSLCertificateKeyFile /etc/ssl/key.key SSLCertificateChainFile /etc/ssl/ca.crt ErrorLog "/var/log/httpd/snappass-error.log" CustomLog "/var/log/httpd/snappass-access.log" combined ProxyPass / http://0.0.0.0:5000/ ProxyPassReverse / http://0.0.0.0:5000/ </VirtualHost>

ck-7 avatar Jan 18 '21 11:01 ck-7