abac0-leakabac0-meicompt_changesgec13mei-idmei-rt0-nmei_rt0mei_rt2mei_rt2_fix_1meiyap-rt1meiyap1rt2tvf-new-xml
Last change
on this file since fbb591e was
06e2fc5,
checked in by Mike Ryan <mikeryan@…>, 14 years ago
|
add swig
|
-
Property mode set to
100755
|
File size:
576 bytes
|
Line | |
---|
1 | #!/usr/bin/python |
---|
2 | |
---|
3 | import sys |
---|
4 | from ABAC import * |
---|
5 | import pprint |
---|
6 | |
---|
7 | pp = pprint.PrettyPrinter(indent=4) |
---|
8 | |
---|
9 | if len(sys.argv) < 2: |
---|
10 | print "Usage: prover.py <keystore>" |
---|
11 | exit(1) |
---|
12 | |
---|
13 | keystore = sys.argv[1] |
---|
14 | |
---|
15 | libabac_init() |
---|
16 | |
---|
17 | ctx = Context() |
---|
18 | ctx.load_directory(keystore) |
---|
19 | |
---|
20 | (success, credentials) = ctx.query( |
---|
21 | "3f1aca4c5911b345d81c5f1a77675dce13249d0c.fed_create", |
---|
22 | "5839d714b16bbe108642c5eb586c2173420bed19", |
---|
23 | ) |
---|
24 | |
---|
25 | for credential in credentials: |
---|
26 | print "credential %s <- %s" % (credential.head().string(), credential.tail().string()) |
---|
27 | # pp.pprint(credential) |
---|
28 | |
---|
29 | libabac_deinit() |
---|
Note: See
TracBrowser
for help on using the repository browser.