Not logged in. · Lost password · Register
Forum: General Help and Support Development RSS
http code on authorisation error
Avatar
ishayahu #1
Member for 2 months · 1 post
Group memberships: Members
Show profile · Link to this post
Subject: http code on authorisation error
Hi!
I'm developing now a system to backup and testing backup of DokuWiki. For that, I'm running spider scrapy to get content of all pages and compute it's md5s. And the question is: how I can check authorization error?
In scrapy tutorial it is something like that:

# check login succeed before going on
            if b"authentication failed" in response.body:
                self.logger.error("Login failed")
                return

but checking for that text is a bad idea: it could be in DokuWiki page. So better way is sending the corresponding HTTP code. Can I setup wiki to send that code instead of 200?
Close Smaller – Larger + Reply to this post:
Verification code: VeriCode Please enter the word from the image into the text field below. (Type the letters only, lower case is okay.)
Smileys: :-) ;-) :-D :-p :blush: :cool: :rolleyes: :huh: :-/ <_< :-( :'( :#: :scared: 8-( :nuts: :-O
Special characters:
Go to forum
Imprint
This board is powered by the Unclassified NewsBoard software, 20150713-dev, © 2003-2015 by Yves Goergen
Current time: 2019-02-16, 16:56:55 (UTC +01:00)