Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fixed plone.protect issue #6 #7

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

fixed plone.protect issue #6 #7

wants to merge 1 commit into from

Conversation

iham
Copy link

@iham iham commented Feb 28, 2017

fixed by adding token to request

@iham
Copy link
Author

iham commented Feb 28, 2017

doesn't disable CSRF checks like in #5

@@ -29,6 +31,9 @@ class pdfpeekUtilView(BrowserView):
def process_conversion_queue(self):
"""process the queue.
"""
token = createToken()
self.request.set('_authenticator', token)

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wouldn't it be better to disable the csrf protection explicitly instead of adding a generated token to the request? In the end this still circumvents the csrf protection, which is ok, but then I would rather use the IDisableCSRFProtection as it's done in PR #5

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

as i am not into that CSRF stuff i wasn't sure if disabling any security feature is a good thing and worked out that solution without changing any protection mechanisms, or touching it ;)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants