jMyles
|
54d593f536
|
Rethinking PolicyOffer more broadly - it's now a Contract, which is able to formulate its own payload.
|
2017-12-14 12:15:10 -08:00 |
jMyles
|
021f7a25d5
|
.enact() for Policy
|
2017-12-14 12:14:37 -08:00 |
jMyles
|
f68bd91510
|
Policy ID is immaterial now. Closes #38 wontfix.
|
2017-12-14 11:40:46 -08:00 |
jMyles
|
f5abf099af
|
New find_n_ursulas method for Policy.
|
2017-12-14 11:40:23 -08:00 |
jMyles
|
56b2fab5bc
|
Moving activate to PolicyOffer.
|
2017-12-14 11:40:09 -08:00 |
jMyles
|
5638af4e9e
|
Eh, this exception has lived in the wrong place its whole life.
|
2017-12-14 11:39:38 -08:00 |
jMyles
|
1fb92890bb
|
Making KFrag hashable; preparing to use it as a key in `_active_ursulas`.
|
2017-12-14 11:39:17 -08:00 |
jMyles
|
c4135b520f
|
Alice passes uri and kFrags to make a Policy.
|
2017-12-14 11:22:20 -08:00 |
jMyles
|
847a0e0e99
|
Policy now takes multiple kFrags and a URI as arguments.
|
2017-12-14 11:22:00 -08:00 |
jMyles
|
f5a0db8603
|
Moving craft_offer to Policy.
|
2017-12-14 11:21:37 -08:00 |
jMyles
|
7f7139e24f
|
Moving 'n' to Policy.
|
2017-12-14 11:21:16 -08:00 |
jMyles
|
8435ddccdf
|
Alice now makes a Policy instead of a PolicyGroup.
|
2017-12-14 11:20:57 -08:00 |
jMyles
|
899049c3d7
|
Moved pFrag down to Policy; pFrag stand-in for PolicyGroup.
|
2017-12-14 10:49:15 -08:00 |
jMyles
|
fcc3636934
|
Found a pFrag that escaped refactor.
|
2017-12-13 20:09:34 -08:00 |
jMyles
|
ac10e6a3da
|
Merge commit for various Policy and testing Work after PRs are merged.
|
2017-12-13 10:41:55 -08:00 |
jMyles
|
267647a07b
|
Don't need TreasureMap setter anymore.
|
2017-12-13 10:32:44 -08:00 |
jMyles
|
ff19d7f276
|
Payload has always incorrectly used the encrypted TreasureMap instead of ChallengePack - we didn't notice because we aren't doing challenges yet.
|
2017-12-13 10:32:10 -08:00 |
jMyles
|
38e692a526
|
Making it easier to get an hrac from outside PolicyGroup.
|
2017-12-13 10:31:31 -08:00 |
jMyles
|
6554df9c03
|
hash convenience method can just be static.
|
2017-12-13 10:31:15 -08:00 |
jMyles
|
9541aa8519
|
Bob can reconstitute a PolicyGroup before he has the PFrag; nothing wrong with that.
|
2017-12-13 10:30:47 -08:00 |
jMyles
|
af969c3ff7
|
Bob now gets a TreasureMap from just an Alice and URI (not a PolicyGroup).
|
2017-12-13 10:30:08 -08:00 |
jMyles
|
44438e6a50
|
Moving publish_treasure_map down to PolicyGroup.
|
2017-12-13 10:29:21 -08:00 |
jMyles
|
451095326f
|
Adding __len__ for TreausureMap (kinda surprised we got by without it until now).
|
2017-12-11 17:03:07 -08:00 |
jMyles
|
df013d6a00
|
More replacements of PolicyGroup for the simple hrac.
|
2017-12-11 17:02:45 -08:00 |
jMyles
|
cbae3d666e
|
Lookup TreasureMap with provided hrac. It's a good idea to test this, but it's untested as yet.
|
2017-12-11 17:00:36 -08:00 |
jMyles
|
673620e721
|
Bob doesn't need a PolicyGroup to generate work orders; an hrac will do.
|
2017-12-11 16:58:40 -08:00 |
jMyles
|
588ee82d8e
|
Store TreasureMap when finding from DHT.
|
2017-12-11 16:56:00 -08:00 |
jMyles
|
57b4450d59
|
Look in own TreasureMaps when following.
|
2017-12-11 16:55:35 -08:00 |
jMyles
|
a5fbc5c38d
|
Bob will store TreasureMaps now.
|
2017-12-11 16:55:00 -08:00 |
jMyles
|
f8d67c83d6
|
BaseClass for NetworkyStuff will just return NotImplemented when asked to find a competitive rate.
|
2017-12-11 14:44:32 -08:00 |
jMyles
|
74f51e77f3
|
New deposit logic for grant: Alice can supply a deposit, look at her default deposit, or, if implemented in her network client, find a competitive rate.
|
2017-12-11 14:43:51 -08:00 |
jMyles
|
1a6650f3e9
|
convenience method for crafting an offer from a PolicyGroup
|
2017-12-09 17:21:25 -08:00 |
jMyles
|
0cf82a4a0c
|
grant method.
|
2017-12-09 17:21:08 -08:00 |
jMyles
|
fd38b2421e
|
Alice gets a PolicyManager at __init__.
|
2017-12-09 17:19:30 -08:00 |
jMyles
|
f5ef7c6eaf
|
Sketch of marking a WorkOrder complete.
|
2017-12-07 20:40:21 -08:00 |
jMyles
|
8c243ed399
|
A WorkOrder is only as long as its PFrags.
|
2017-12-07 20:38:51 -08:00 |
jMyles
|
537a782100
|
Pushing reencrypt logic down into actual NetworkyStuff instead of just the mock. Makes me psyched!
|
2017-12-07 20:37:08 -08:00 |
jMyles
|
748aea9746
|
Added TODO showing where Ursula needs to sign response - See #141.
|
2017-12-07 20:36:36 -08:00 |
jMyles
|
ad0a2a59cf
|
Check that Ursula sent back the proper number of CFrags.
|
2017-12-07 20:36:09 -08:00 |
jMyles
|
2b1ca0d0d9
|
New concept for saving WorkOrders by Bob.
|
2017-12-07 20:35:38 -08:00 |
jMyles
|
647e0e4fd7
|
Bob can now lookup past work orders by PFrag since #137 is closed.
|
2017-12-07 00:36:35 -08:00 |
jMyles
|
1f923aaeab
|
That thing in a PolicyGroup isn't an EncryptedKey; it's a PFrag.
|
2017-12-05 12:54:19 -08:00 |
jMyles
|
2d4a57f463
|
RepeatingBytestringSplitter - to get any number of CFrags from the HTTP response.
|
2017-12-05 12:53:39 -08:00 |
jMyles
|
295e4c6e9b
|
Overhaul of CFrag class; adding more robust protections.
|
2017-12-05 12:53:18 -08:00 |
jMyles
|
32658b08ee
|
Reconstituting an EncryptedKey from deserialized key data.
|
2017-12-05 12:52:43 -08:00 |
jMyles
|
73f1a62141
|
Reconsituting CFrag from the full reencrypted_data payload.
|
2017-12-05 12:52:10 -08:00 |
jMyles
|
0b21f67323
|
Ursula tracks WorkOrders. Probably makes more sense to serialize these and put them in her datastore.
|
2017-12-05 12:51:44 -08:00 |
jMyles
|
335320c566
|
Convenience method for finding a known Ursula by Bob.
|
2017-12-05 12:51:01 -08:00 |
jMyles
|
ae4a6f87ec
|
WorkOrder now takes a Bob instead of just Bob's key.
|
2017-12-05 12:50:18 -08:00 |
jMyles
|
028b28cb58
|
Bob's __init__ was flawed; didn't pass args to super.
|
2017-12-05 12:49:14 -08:00 |
jMyles
|
074788f10f
|
Proper __eq__ logic for Characters - we'll need this to find WorkOrders belonging to Bob.
|
2017-12-05 12:48:40 -08:00 |
jMyles
|
61bcb62862
|
WorkOrder Payload simplified using PFrags.
|
2017-12-04 17:18:23 -08:00 |
jMyles
|
6e3d8bb7b5
|
REST Response is bytestream of concat'd cFrags.
|
2017-12-04 17:17:56 -08:00 |
jMyles
|
d90a2649e9
|
Can't represent pfrag as bytes; this is a blocker for now. See #137.
|
2017-12-04 17:17:28 -08:00 |
jMyles
|
baa27f53f7
|
Storing encrypted key (ie, pfrag) as part of PolicyGroup.
|
2017-12-04 17:17:28 -08:00 |
jMyles
|
c4cbff3359
|
Tests that show Bob that Bob is able to issue a WorkOrder via REST.
|
2017-12-04 17:17:28 -08:00 |
jMyles
|
df9f24e612
|
Mock network stuff to call reencrypt.
|
2017-12-04 17:17:28 -08:00 |
jMyles
|
3bda4b4a3c
|
Ursula's REST endpoint for reencryption.
|
2017-12-04 17:17:28 -08:00 |
jMyles
|
593fb25db2
|
Bob signs pfrags and metadata.
|
2017-12-04 17:17:28 -08:00 |
jMyles
|
4494ea869e
|
Bob can generate however many work orders he likes.
|
2017-12-04 17:17:28 -08:00 |
jMyles
|
4509ec0fc8
|
Pointing out where deterministic Ursula ID is useful. See #136.
|
2017-12-04 17:17:28 -08:00 |
jMyles
|
8cca28439e
|
Work Order logic per-Ursula.
|
2017-12-04 17:17:28 -08:00 |
jMyles
|
07ceb085d1
|
Clarifying which interface we're talking about. See #134.
|
2017-12-04 17:17:28 -08:00 |
jMyles
|
be35217f61
|
Bob can generate WorkOrder.
|
2017-12-04 17:17:28 -08:00 |
jMyles
|
c624f3c3d5
|
WorkOrder class.
|
2017-12-04 17:17:28 -08:00 |
jMyles
|
ff04578dc3
|
CFrag and tests.
|
2017-12-04 17:17:13 -08:00 |
jMyles
|
2100acb680
|
Implemented PFrag in API. Closes #137.
|
2017-12-04 16:27:32 -08:00 |
jMyles
|
ceb39d4ab7
|
PFrag class.
|
2017-12-04 16:26:52 -08:00 |
jMyles
|
4fab47cac3
|
Proper dunders with tests for kfrag retrieval and deserialization. Fixes #138.
|
2017-12-04 15:23:40 -08:00 |
jMyles
|
8ce87a3369
|
Better kfrag splitter. Reveals that test_kfrag_sqlite wasn't actually testing kfrag reconstruction. See #138.
|
2017-12-04 14:39:53 -08:00 |
jMyles
|
60d5846774
|
Don't need the part lengths anymore.
|
2017-12-04 14:38:43 -08:00 |
jMyles
|
9f41dfd06c
|
Using KFrag with BytestringSplitter. Feels good.
|
2017-12-04 14:14:56 -08:00 |
jMyles
|
2fc80d3414
|
Providing KFrag compatibility.
|
2017-12-04 13:58:11 -08:00 |
jMyles
|
07ddefa909
|
Making API return KFrag instances.
|
2017-12-04 13:57:55 -08:00 |
jMyles
|
7ebe8eb56c
|
First sketch of KFrag class.
|
2017-12-04 13:08:21 -08:00 |
jMyles
|
75dc1b011a
|
Sketching things out here.
|
2017-12-02 17:33:49 -08:00 |
jMyles
|
09d189da47
|
Changing actor ID to something more realistic. This may become the basis for looking up an actor if we ever represent them with REST.
|
2017-11-27 20:27:12 -08:00 |
jMyles
|
16be6e3b97
|
Another variable type hint removal.
|
2017-11-22 09:27:58 -08:00 |
jMyles
|
f7539f7575
|
Python 3.5 doesn't like inline type-hints for variables. This can be a class anyway.
|
2017-11-22 09:23:40 -08:00 |
jMyles
|
d250a2bd4a
|
find_n_ursulas no longer returns a list.
|
2017-11-21 22:13:35 -08:00 |
jMyles
|
08644afc5d
|
Type hint for list in blockchain_client.
|
2017-11-21 22:13:11 -08:00 |
jMyles
|
47328e8941
|
Default methods for Keypair.
|
2017-11-21 22:12:50 -08:00 |
jMyles
|
a3b9960fbd
|
Added sentinel for missing return value - see https://github.com/python/mypy/issues/4223#issuecomment-342865133.
|
2017-11-21 22:12:27 -08:00 |
jMyles
|
5f4b5f5cca
|
Type for Keypair class.
|
2017-11-21 22:10:47 -08:00 |
jMyles
|
e34ddef071
|
New names for return values.
|
2017-11-21 22:10:27 -08:00 |
jMyles
|
fce308fc62
|
Fixed some tuple type hints with the proper number of expected members.
|
2017-11-21 22:09:58 -08:00 |
jMyles
|
63d1b9d082
|
encrypt_for takes Character, not str.
|
2017-11-21 22:09:29 -08:00 |
jMyles
|
6886b6bb0a
|
Adding type hints for methods that return None.
|
2017-11-21 22:08:02 -08:00 |
jMyles
|
167ee66aa0
|
Changing fixture 'fake_ursulas' to just 'ursulas'.
|
2017-11-21 22:06:52 -08:00 |
jMyles
|
1e67468013
|
Properly delivering Alice's signature in the case that she signs the cleartext and includes it in the ciphertext.
|
2017-11-21 22:02:26 -08:00 |
jMyles
|
2f0b483ba3
|
Not using msgpack for protocols anymore! All concat and split now.
|
2017-11-21 20:21:02 -08:00 |
jMyles
|
29d4089da1
|
Just a fake list for now as a blockchain client.
|
2017-11-21 20:20:38 -08:00 |
jMyles
|
4c507fe22d
|
Some cleanup; better docstring for Character.__init__
|
2017-11-21 20:20:15 -08:00 |
jMyles
|
436f2b1c05
|
Actually, we weren't using the rest module.
|
2017-11-21 12:41:32 -08:00 |
jMyles
|
4ff94f385b
|
Ursula can't just willy-nilly spin up an in-memory db anymore.
|
2017-11-21 12:04:33 -08:00 |
jMyles
|
83e63a2ffe
|
Warning when using default DB for Ursula, which does not persist.
|
2017-11-21 09:38:04 -08:00 |
jMyles
|
4563ef2eca
|
HRAC in URL as hex instead of encoded bytes.
|
2017-11-20 19:49:43 -08:00 |
jMyles
|
c0639349c7
|
Changed method to 'enact_policy'. Move HRAC to URL instead of HTTPS payload.
|
2017-11-20 19:23:25 -08:00 |
jMyles
|
8be498629b
|
Fixed length of test bytes for keystore.
|
2017-11-20 19:20:18 -08:00 |
jMyles
|
17ff9a37cf
|
Changed 'set_kfrag' to 'set_policy'.
|
2017-11-20 19:19:37 -08:00 |