summaryrefslogtreecommitdiff
path: root/src/leap/bitmask/bonafide/_http.py
AgeCommit message (Collapse)Author
2018-01-25[bug] do not fail if the provider does not allow anonymous vpnKali Kaneko
Since bonafide was not catching the error 401, an attempt to bootstrap a provider that does not support anonvpn with the new setup was resulting in a json that was containing only an error message. this was producing an error when trying to access the configuration for that provider's EIP section. we now avoid writing a json config file if an error 401 is found, and also catch the exception for a ValueError when the EIP section is not found in the provider's configuration.
2017-09-21[bug] fix initialization of default parameter to mutable data structureKali Kaneko
whoever wrote this in the first place needs to get introduced to import-time initialization, even if it was me. one of the nastiest python gotchas in my opinion :)
2017-09-21[bug] do not send if-modified-header if file does not existKali Kaneko
just to make the logic clear. we should probably check that the file is not empty and it has valid json (sanitized against the spec).
2017-09-20[feat] check if there are newest configuration filesKali Kaneko
here we port the if-modified-since conditional mechanism, so that we only write the config if it is newer than whan we have. we also add a line with the status code to the logs, so that it's easier to debug. note that the 'configs.json' file is never returning 304. - Resolves: #8773
2016-08-29[pkg] move bonafide source to leap.bitmask.bonafideKali Kaneko (leap communications)