=== Peng__ is now known as Peng | ||
xnox | cjwatson, juliank - downloaded SKS webserver source code, to browse what it supports.... And I think everything what we need already exists | 09:29 |
---|---|---|
xnox | https://keyserver.ubuntu.com/pks/lookup?op=get&exact=on&search=0x2d9df1e22f3416238d46f49f157951fe4031d287 | 09:30 |
xnox | bah wrong url | 09:30 |
xnox | https://keyserver.ubuntu.com/pks/lookup?op=get&options=mr&exact=on&search=0x2d9df1e22f3416238d46f49f157951fe4031d287 | 09:30 |
xnox | downlaods ASC armored public key, with exact match on the fingerprint. | 09:30 |
xnox | it's not clean, but it's perfectly usable by the new enough apt. | 09:31 |
xnox | (in the web-browser that gets downloaded as gpgkey.asc) | 09:31 |
cjwatson | xnox: I mean, we could, but I'd rather just use the existing interfaces that LP already uses. | 10:06 |
cjwatson | i.e. retrieve the key in the usual way (which is op=get&exact=on) and then format it ourselves | 10:06 |
cjwatson | that way we can cache it using our existing strategies | 10:07 |
xnox | as in launchpad.net to proxy the results for that. | 10:07 |
xnox | without 'options=mp' one gets and html page with header bar; with 'options=mp' one gets plain text, armored key | 10:08 |
xnox | so if you are adding code in launchpad to fetch keys, 'options=mp' is useful. | 10:08 |
cjwatson | We already have code in Launchpad to fetch keys | 10:09 |
cjwatson | lib/lp/services/gpg/handler.py | 10:09 |
* xnox looks | 10:09 | |
cjwatson | So I'd rather fetch the key in the usual way we already do, and then use gpgme to armor it | 10:09 |
cjwatson | Because that way the same keyserver result can be cached locally and has a better chance of being useful for other requests | 10:10 |
xnox | ack | 10:11 |
cjwatson | In fact we already have all the necessary code. | 10:13 |
cjwatson | PymeKey.export will do it | 10:13 |
cjwatson | (Because PymeKey._getContext sets armor = True | 10:14 |
cjwatson | ) | 10:14 |
cjwatson | So it should literally be just handler = getUtility(IGPGHandler); pub_key = handler.retrieveKey(fingerprint); key_text = pub_key.export() | 10:15 |
cjwatson | Sorry, I didn't realise you thought we thought we'd need any special keyserver support for this. | 10:15 |
cjwatson | Could have saved you the bother. | 10:15 |
cjwatson | wgrant: Could you re-review https://code.launchpad.net/~cjwatson/launchpad/job-oops-timeline/+merge/341554, please? I added some gadgetry to avoid BranchScanJob producing giant timelines, since that seems likely to be the worst offender. | 20:43 |
wgrant | cjwatson: Ah, clever. | 21:35 |
cjwatson | Thanks. | 22:08 |
cjwatson | Also, if you reference any kind of model object from your timeline then the resulting reference cycles are *hell* to debug. | 22:08 |
cjwatson | I tried using objgraph which sort of vaguely helped a little but also produced enormous output. | 22:09 |
Generated by irclog2html.py 2.7 by Marius Gedminas - find it at mg.pov.lt!