Fix typos, semantics and some other corrections
Before adoption: this commit came in with the history the project adopted, so no landing records it.
authored by Lowell Abbott · committed by Lowell Abbott · parent 8459ced · Browse files · 1 file·+20 added−23 removed
This commit
State
Before adoption: this commit came in with the history the project adopted, so no landing records it.
Diff stats
1 file+20 added−23 removed
- other:+20 added−23 removed
Provenance
- Commit
98b0f96- Tree
c53ef5b- Author
Lowell Abbott <lowell.abbott@gmail.com>- Committer
Lowell Abbott <lowell.abbott@gmail.com>- Parent
8459ced
1 file changed+20 added−23 removed
modified:docs/security.rst+20 added-23 removed
107 unmodified lines108 109 SSL/HTTPS110 ---------111 112-For implementing HTTPS on your server112+For implementing HTTPS on your server.113 114-Below some packages in suggestion order that implements this protocol:114+Below are some packages that implement this protocol:115 116 * `flask-talisman <https://github.com/GoogleCloudPlatform/flask-talisman>`_117 * `flask-sslify <https://github.com/kennethreitz/flask-sslify>`_118 * `flask-secure-headers <https://github.com/twaldear/flask-secure-headers>`_119 120 Security Headers121 ----------------122 123-This sections contains sections headers supported by Flask and a list of packages in suggestion order that implements it123+This section contains a list of headers supported by Flask and some packages that implements them.124 125 `Content Security Policy <https://csp.withgoogle.com/docs/index.html>`_ (CSP)126 -----------------------------------------------------------------------------127 128-For enhancing security and preventing common web vulnerabilities such as cross-site scripting and MITM related attacks128+Enhance security and prevents common web vulnerabilities such as cross-site scripting and MITM related attacks.129 130-Example130+Example:131 132 .. sourcecode:: html133 134 Content-Security-Policy: default-src https:; script-src 'nonce-{random}'; object-src 'none'135 136 137-To learn more check `this <https://csp.withgoogle.com/docs/index.html>`_137+See also `Content Security Policy <https://csp.withgoogle.com/docs/index.html>`_.138 139 * `flask-talisman <https://github.com/GoogleCloudPlatform/flask-talisman>`_140 * `flask-csp <https://github.com/twaldear/flask-csp>`_141 * `flask-secure-headers <https://github.com/twaldear/flask-secure-headers>`_142 143 `HTTP Strict Transport Security <https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Strict-Transport-Security>`_ (HSTS)144 ------------------------------------------------------------------------------------------------------------------------------145 146+Redirects http requests to https on all urls, preventing MITM attacks.147 147-For automatically redirect HTTP to HTTPS on all the website url's and prevent MITM attacks148+Example:149 149-Example150-150 .. sourcecode:: html151 152 Strict-Transport-Security: max-age=<expire-time 153 Strict-Transport-Security: max-age=<expire-time>; includeSubDomains 154 Strict-Transport-Security: max-age=<expire-time>; preload 155 157-To learn more check `this <https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Strict-Transport-Security>`_ 156+See also `Strict Transport Security <https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Strict-Transport-Security>`_. 157 159-158 * `flask-talisman <https://github.com/GoogleCloudPlatform/flask-talisman>`_159 * `flask-sslify <https://github.com/kennethreitz/flask-sslify>`_160 * `flask-secure-headers <https://github.com/twaldear/flask-secure-headers>`_161 162 `X-FRAME-OPTIONS <https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-Frame-Options>`_ (Clickjacking protection)163 -------------------------------------------------------------------------------------------------------------------------166-Prevents the client clicking page elements outside of the website avoiding hijacking or UI redress attacks164 165+Prevents the client from clicking page elements outside of the website, avoiding hijacking or UI redress attacks.166 167 .. sourcecode:: html168 169 X-Frame-Options: DENY 170 X-Frame-Options: SAMEORIGIN171 X-Frame-Options: ALLOW-FROM https://example.com/172 175-To learn more check `this <https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Strict-Transport-Security>`_ 173+See also `X-Frame-Options <https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-Frame-Options>`_. 174 175 * `flask-talisman <https://github.com/GoogleCloudPlatform/flask-talisman>`_176 * `flask-secure-headers <https://github.com/twaldear/flask-secure-headers>`_177 178 `X-Content-Type-Options <https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-Content-Type-Options>`_179 -------------------------------------------------------------------------------------------------------------180 183-Prevents XSS by blocking requests on clients and forcing then to read the content type instead of first opening it.181+Prevents XSS by blocking requests on clients and forcing them to read the content type instead of first opening it.182 183 .. sourcecode:: html184 185 X-Content-Type-Options: nosniff186 189-To learn more check `this <https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-Content-Type-Options>`_ 187+See also `X-Content-Type-Options <https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-Content-Type-Options>`_. 188 191-189 * `flask-talisman <https://github.com/GoogleCloudPlatform/flask-talisman>`_190 * `flask-secure-headers <https://github.com/twaldear/flask-secure-headers>`_191 192 `Cookie options <https://developer.mozilla.org/en-US/docs/Web/HTTP/Cookies#Secure_and_HttpOnly_cookies>`_193 ----------------------------------------------------------------------------------------------------------194 198-For setting cookies on client-side storage195+For setting cookies on client-side storage.196 200-Example197+Example:198 199 .. sourcecode:: html200 201 Set-Cookie: [cookie-name]=[cookie-value] 202 206-To learn more check `this <https://developer.mozilla.org/en-US/docs/Web/HTTP/Cookies#Secure_and_HttpOnly_cookies>`_203+See also `HTTP cookies <https://developer.mozilla.org/en-US/docs/Web/HTTP/Cookies#Secure_and_HttpOnly_cookies>`_ .204 205 * `flask-talisman <https://github.com/GoogleCloudPlatform/flask-talisman>`_206 * `flask-secure-headers <https://github.com/twaldear/flask-secure-headers>`_207 208 `HTTP Public Key Pinning <https://developer.mozilla.org/en-US/docs/Web/HTTP/Public_Key_Pinning>`_ (HPKP)209 -------------------------------------------------------------------------------------------------------210 214-For associating clients with web servers throught a certificate key and prevent MITM attacks211+For associating clients with web servers through a certificate key and prevent MITM attacks.212 216-Example213+Example:214 215 .. sourcecode:: html216 217 Public-Key-Pins: pin-sha256="base64=="; max-age=expireTime [; includeSubDomains][; report-uri="reportURI"] 218 222-To learn more check `this <https://developer.mozilla.org/en-US/docs/Web/HTTP/Public_Key_Pinning>`_219+See also `Public Key Pinning <https://developer.mozilla.org/en-US/docs/Web/HTTP/Public_Key_Pinning>`_.220 221 * `flask-talisman <https://github.com/GoogleCloudPlatform/flask-talisman>`_222 * `flask-secure-headers <https://github.com/twaldear/flask-secure-headers>`_223 227-References:224+References225 -----------226 227 * https://docs.djangoproject.com/en/1.11/topics/security/228 * https://blog.appcanary.com/2017/http-security-headers.html2 unmodified lines