jimklo / lrsignature Goto Github PK
View Code? Open in Web Editor NEWLearning Registry resource document signing, validation, and key managment module
License: Apache License 2.0
Learning Registry resource document signing, validation, and key managment module
License: Apache License 2.0
I upgraded LRSignature to version 0.1.10 using
pip install --upgrade LRSignature
per guidance that 0.1.10 includes support for harvested json.
Indeed, harvested json now verifies, but surprisingly obtained json no longer verifies. I validated that the obtained json is valid json data. Here is a gist for the obtained json that fails to verify: https://gist.github.com/1829042
I'm using 64-bit windows 7 with python 2.7.2.
To reproduce:
curl -o harvested.json "http://sandbox.learningregistry.org/harvest/getrecord?request_ID=77d1e7a401da4dd7b00806d37ac7d81a&by_doc_ID=true"
curl -o obtained.json "http://sandbox.learningregistry.org/obtain?request_id=77d1e7a401da4dd7b00806d37ac7d81a&by_doc_ID=T"
type obtained.json | python -m LRSignature.cmd verify --gnupghome "C:/Users/x/AppData/Roaming/gnupg/"
type harvested.json | python -m LRSignature.cmd verify --gnupghome "C:/Users/x/AppData/Roaming/gnupg/"
output:
C:\Development\verify_analysis>type obtained.json | python -m LRSignature.cmd verify --gnupghome "C:/Users/548580/AppData/Roaming/gnupg/"
{"results": [{"doc_ID": "77d1e7a401da4dd7b00806d37ac7d81a", "verified": null}]}
C:\Development\verify_analysis>type harvested.json | python -m LRSignature.cmd verify --gnupghome "C:/Users/548580/AppData/Roaming/gnupg/"
{"results": [{"doc_ID": "77d1e7a401da4dd7b00806d37ac7d81a", "resource_locator":
"http://www.khanacademy.org/video/subtracting--fractions?topic=developmental-math-1", "verified": true}]}
See issue details reported and discussed on LearningRegistry/LearningRegistry#186
When I try to use --gpgbin I rec'd command line errors if the value for --gpgbin contains spaces in the path.
So, if I submit:
--gpgbin "C:\Program Files (x86)\foo\bar"
The command line error indicates that "C:\Program" is invalid as it has truncated the value at the first space.
This works on Mac/Linux:
cat test.download.json | python -m LRSignature.cmd verify
These do not seem to work on Windows. Command line errors:
type test.download.json | python -m LRSignature.cmd verify --gnupghome "C:\path\to\my\keys"
type test.download.json | python -m LRSignature.cmd verify --gnupghome "C:\path\to\my\keys" --gpgbin "C:\path\to\my\gpg.exe"
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.