certbot/certbot-apache/certbot_apache/tests
Joona Hoikkala 3877af6619 Gradually increasing HSTS max-age (#5912)
This PR adds the functionality to enhance Apache configuration to include HTTP Strict Transport Security header with a low initial max-age value.

The max-age value will get increased on every (scheduled) run of certbot renew regardless of the certificate actually getting renewed, if the last increase took place longer than ten hours ago. The increase steps are visible in constants.AUTOHSTS_STEPS.

Upon the first actual renewal after reaching the maximum increase step, the max-age value will be made "permanent" and will get value of one year.

To achieve accurate VirtualHost discovery on subsequent runs, a comment with unique id string will be added to each enhanced VirtualHost.

* AutoHSTS code rebased on master

* Fixes to match the changes in master

* Make linter happy with metaclass registration

* Address small review comments

* Use new enhancement interfaces

* New style enhancement changes

* Do not allow --hsts and --auto-hsts simultaneuously

* MyPy annotation fixes and added test

* Change oldest requrements to point to local certbot core version

* Enable new style enhancements for run and install verbs

* Test refactor

* New test class for main.install tests

* Move a test to a correct test class
2018-06-21 07:27:19 -07:00
..
apache-conf-files Do not parse disabled configuration files from under sites-available on Debian / Ubuntu (#4104) 2017-09-25 12:03:09 -07:00
testdata Apache HTTP01 Improvements 2018-01-16 23:17:08 -08:00
__init__.py s/Let's Encrypt/Certbot certbot-apache 2016-04-13 16:36:53 -07:00
augeas_configurator_test.py Switch from nose to pytest (#5282) 2017-12-01 10:59:55 -08:00
autohsts_test.py Gradually increasing HSTS max-age (#5912) 2018-06-21 07:27:19 -07:00
centos_test.py If restart fails, try alternative restart command if available (#5500) 2018-04-03 14:05:37 -07:00
complex_parsing_test.py Distribution specific override functionality based on class inheritance (#5202) 2017-12-04 11:49:18 -08:00
configurator_test.py Gradually increasing HSTS max-age (#5912) 2018-06-21 07:27:19 -07:00
debian_test.py Enhance verb (#5596) 2018-04-18 11:08:30 -07:00
display_ops_test.py Apache plugin wildcard support for ACMEv2 (#5608) 2018-02-28 11:31:47 -08:00
entrypoint_test.py Distribution specific override functionality based on class inheritance (#5202) 2017-12-04 11:49:18 -08:00
gentoo_test.py If restart fails, try alternative restart command if available (#5500) 2018-04-03 14:05:37 -07:00
http_01_test.py Issue 5951/check untyped defs apache (#5989) 2018-05-15 10:40:32 -07:00
obj_test.py Test coverage & fix 2016-06-25 12:06:43 -07:00
parser_test.py Gradually increasing HSTS max-age (#5912) 2018-06-21 07:27:19 -07:00
tls_sni_01_test.py Add basic HTTP01 support to Apache 2018-01-10 23:35:09 -08:00
util.py Issue 5951/check untyped defs apache (#5989) 2018-05-15 10:40:32 -07:00