Use secure hash algorithm in WebConfiguration.sign_text
Fix: PendingDeprecationWarning: HMAC() without an explicit digestmod argument is deprecated.
The default hash algorithm used by hmac.new is md5. As of today, md5 is so weak
that it's the equivalent of plaintext and can't be considered to be secured at all.
Therefor, we switch to a secure hash algorithm.
The rational for choosing sha3_512 is:
* the recommended algorithm is at least sha_256
* the stronger, the more secured and sha3_512 is the stronger available
* thinking about the future this should keep this part of the code safe long
enough before people think about checking it again
You can read more about choosing a secure hash algorithm in the NIST
recommendations https://csrc.nist.gov/Projects/Hash-Functions/NIST-Policy-on-Hash-Functions
This code modification should normally be transparent since check_text_sign is
exactly this code 'self.sign_text(text) == signature' and that sign_text is
only used in combination with it. The only impact is that the hash is going to
move from 32 char to 128 which might make html page a bit bigger and that
sha3_512 is slow to compute (which is a good thing for security)
.. -*- coding: utf-8 -*-
RSS Channel
-----------
Assuming you have several blog entries, click on the title of the
search box in the left column. A larger search box should appear. Enter::
Any X ORDERBY D WHERE X is BlogEntry, X creation_date D
and you get a list of blog entries.
Click on your login at the top right corner. Chose "user preferences",
then "boxes", then "possible views box" and check "visible = yes"
before validating your changes.
Enter the same query in the search box and you will see the same list,
plus a box titled "possible views" in the left column. Click on
"entityview", then "RSS".
You just applied the "RSS" view to the RQL selection you requested.
That's it, you have a RSS channel for your blog.
Try again with::
Any X ORDERBY D WHERE X is BlogEntry, X creation_date D,
X entry_of B, B title "MyLife"
Another RSS channel, but a bit more focused.
A last one for the road::
Any C ORDERBY D WHERE C is Comment, C creation_date D LIMIT 15
displayed with the RSS view, that's a channel for the last fifteen
comments posted.
[WRITE ME]
* show that the RSS view can be used to display an ordered selection
of blog entries, thus providing a RSS channel
* show that a different selection (by category) means a different channel