The short answer to your question is that you need to ask the "user" service what your "storage" endpoint is. Follow the examples in https://wiki.mozilla.org/Labs/Weave/User/1.0/API to see how to construct your user URL and then ask for the node/weave resource of your account. The body of that response will be the URL for your storage node, and you should direct all future requests to that one.
Best.
Mike
--
Michael Hanson, Mozilla Labs (@michaelrhanson)
> --
> You received this message because you are subscribed to the Google Groups "mozilla-labs-weave-dev" group.
> To post to this group, send email to mozilla-lab...@googlegroups.com.
> To unsubscribe from this group, send email to mozilla-labs-weav...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/mozilla-labs-weave-dev?hl=en.
>
Regards,
Toby Elliott
Mozilla
> --
> You received this message because you are subscribed to the Google Groups "mozilla-labs-weave-dev" group.
> To post to this group, send email to mozilla-lab...@googlegroups.com.
> To unsubscribe from this group, send email to mozilla-labs-weav...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/mozilla-labs-weave-dev?hl=en.
>
>
Hi All,
Thanks to the help this list gave me before, ive got as far as getting
the encrypted objects back, and getting the users (encrypted) private
and public key, and decrypting the private key using the cipher from
the passphrase (i think - not been able to verify im doing this
correctly). Im following the instructions here:
https://wiki.mozilla.org/Labs/Weave/Developer/Crypto
but when I get to the final phase of actually decrypting the data on
the bookmark WBO i seem to be missing the bulk IV - it seems from the
page i referenced that it should be returned in the same hashtable as
the keyring of the wbo, but it isnt... i notice the tutorial is for
v0.5 and we are using v1 now, so maybe that has changed??
Ive looked at jweave for inspiration, but that only seems to implement
the user part of the spec.
Ive downloaded and run the python one mentioned previously in this
thread, and got that running, but when I try to use it, im getting an
error (below), and im not familiar enough with python to diagnose
it... can anyone give me a hint please? i had to install
python-m2crypto (ubuntu) to get it running. It seems the ubuntu im
using has version python-m2crypto (0.18.2-2build1) .
Id really like to have a working example (in any language - im getting
desperate now!) of a self contained lib to get and decode these
things... that python one looks perfect, except ive missed something
that is stopping it from working...
Once I have that, i can use debug messages to ensure im getting the
same values in my c# port...
thanks
George
ing: the sha module is deprecated; use the hashlib module instead
import sha as SHA1
DEBUG:root:Created WeaveStorageContext for ripnetuk: storage node is
https://phx-sync107.services.mozilla.com
DEBUG:root:Making GET request to
https://phx-sync107.services.mozilla.com/1.0/ripnetuk/storage/bookmarks?full=1
with auth (REDACTED)
DEBUG:root:Fetching encrypted private key from server
DEBUG:root:Making GET request to
https://phx-sync107.services.mozilla.com/1.0/ripnetuk/storage/keys/privkey?full=1
with auth (REDACTED)
DEBUG:root:Decrypting encrypted private key
Traceback (most recent call last):
File "./weave.py", line 760, in <module>
itemObject = json.loads(crypto.decrypt(itemText))
File "./weave.py", line 605, in decrypt
self.fetchPrivateKey()
File "./weave.py", line 488, in fetchPrivateKey
cipher.set_padding(padding=1)
AttributeError: Cipher instance has no attribute 'set_padding'
Hi,
Further to the above, ive commented out the like about set_padding,
and now the python implementation seems to be missing the bulk IV key
as well, as evidenced by this error:
DEBUG:root:Making GET request to
https://phx-sync107.services.mozilla.com/1.0/ripnetuk/storage/crypto/bookmarks
with auth ***********************
Traceback (most recent call last):
File "./weave.py", line 760, in <module>
itemObject = json.loads(crypto.decrypt(itemText))
File "./weave.py", line 607, in decrypt
self.fetchBulkKey(encryptionLabel)
File "./weave.py", line 549, in fetchBulkKey
bulkIV = base64.decodestring(keyPayload['bulkIV'])
KeyError: 'bulkIV'
so it seems the only known working implementation (AFAICT) is the
actual firefox plugin... - maybe the spec has changed to get the
bulkIV another way???
thanks
George
Hi All,
For reference, the one here
http://pypi.python.org/pypi/python-weave
works :) (after removing the set_padding line from cyrpto.py)...
finally... i have source code that actually does what I want (in fact,
converting to rss as per the example is almost /exactly/ what i
want... tempted to just use it as-is, although I will have a go at a
port to c#...)
thanks for the help (especially the leg-up that i had to use the user
api to get the cluster)
:)
george