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

enabled arclink decryption during download #1360

Merged
merged 6 commits into from Mar 5, 2017
Merged

Conversation

barsch
Copy link
Member

@barsch barsch commented Mar 29, 2016

lesser memory footprint while having the same execution speed as before

@barsch
Copy link
Member Author

barsch commented Mar 29, 2016

coverage/coveralls lies - it includes files which were not changed in this PR - however I really love the idea of this feature if it would work ...

@krischer
Copy link
Member

Yea coveralls is funny sometimes...no clue why it lists untouched files.

The PR itself looks fine to me. I assume you locally tested on py2 and py3?

@barsch
Copy link
Member Author

barsch commented Mar 29, 2016

tests were fine for windows - still would be nice if someone would test it manually on linux

@krischer
Copy link
Member

I get lots of timeouts when running test_decrypt.py but can run the normal arclinks tests just fine. Is this expected? Is encrypted data send over a different port?

@barsch
Copy link
Member Author

barsch commented Mar 29, 2016

hmm not good - I'll check at home if this is still running for me and report back - thanks for testing

@barsch
Copy link
Member Author

barsch commented Mar 29, 2016

@krischer
Copy link
Member

I see. I'll test at home.

@krischer
Copy link
Member

FYI: I just pushed a commit to this branch that allows to run the crypto tests with either supported crypto library.

@barsch
Copy link
Member Author

barsch commented Mar 29, 2016

careful: EVPError is only defined for M2Crypto ! -> unfortunatly as far I tested pycrypto does not raise anything if there is an error during decryption - so we have to stick with M2Crypto as default and only take pyCrypto as fallback

@krischer
Copy link
Member

Hmm...there must be a way to figure out if the decrypt was successful, right? How does m2crypto even know? I mean we could always check the resulting miniseed file but m2crypto clearly does something else.

@barsch
Copy link
Member Author

barsch commented Mar 29, 2016

while using pycrypto it just fails later - either because it can't unpack using bzip2 or it can't read as its not a valid mseed

AFAIK m2crypto checks in the final call https://github.com/obspy/obspy/blob/master/obspy/clients/arclink/decrypt.py#L66 - so we could look into that

@megies megies added this to the 1.1.0 milestone Mar 31, 2016
@megies
Copy link
Member

megies commented Oct 5, 2016

+TESTS:clients.arclink

Travis should run ArcLink test suites for future commits/pushes to this branch now (see here). Please ping me if it doesn't work..

@megies
Copy link
Member

megies commented Nov 15, 2016

What's the status here, @barsch @krischer?

@barsch
Copy link
Member Author

barsch commented Nov 16, 2016

the later commit from @krischer does imho not work - see comment above - so either we stick with my orginal implementation, leave it as it is or find something better

and triggering a new test run did not work, or?

@megies
Copy link
Member

megies commented Nov 16, 2016

and triggering a new test run did not work, or?

I rebased and force-pushed right now, that will trigger CI..

@megies
Copy link
Member

megies commented Nov 16, 2016

Current Travis commit status includes Arclink tests: https://travis-ci.org/obspy/obspy/builds/176344138

Not sure if tests cover decryption, though?

@megies
Copy link
Member

megies commented Nov 17, 2016

I'll bump this to 1.2.0. Feel free to add to 1.1.0 if it gets ready in the next couple of weeks.

@barsch
Copy link
Member Author

barsch commented Mar 5, 2017

imho ready to merge

Copy link
Member

@megies megies left a comment

Choose a reason for hiding this comment

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

Yep, CI looks good (we really should figure out why we have these erratic arclink "UNSET" problems.. or well.. once the VCR stuff is ready we're rid of it I guess)

Rebased on current master, mainly to get rid of some merge commits within this branch..

@barsch
Copy link
Member Author

barsch commented Mar 5, 2017

failing test is not related - merging

@barsch barsch merged commit 62ef604 into master Mar 5, 2017
@barsch barsch deleted the arclink_decryption branch March 5, 2017 22:57
@megies
Copy link
Member

megies commented Mar 13, 2017

@barsch this PR should also have modified arclink extra/optional dependencies.. anybody know how to modify a set of OR dependencies in setup.py? I couldn't find it..

https://github.com/obspy/obspy/blob/master/setup.py#L116

Should be semantically be something like..

 'arclink': ['m2crypto | pycrypto | cryptography'],

@barsch
Copy link
Member Author

barsch commented Mar 13, 2017

I don't think there is such option - I would take it out completely and just document it

btw: pycryptodome does also work - its an drop-in replacement for pycrypto

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

Successfully merging this pull request may close these issues.

None yet

3 participants