Changeset 4315c0e for axis


Ignore:
Timestamp:
Apr 1, 2011 10:25:10 AM (9 years ago)
Author:
Ted Faber <faber@…>
Branches:
axis_example, compt_changes, info-ops, master
Children:
140fb80
Parents:
1294d29
Message:

Send the Identity cert with the credential!! (Also fix parameters)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • axis/Create.java

    r1294d29 r4315c0e  
    8686        byte[] nsContents = null;
    8787        try {
    88             nsContents = readNsFile(new File(args[1]));
    89             AbacID = new Identity(new File("./emulab.pem"));
     88            nsContents = readNsFile(new File(tclFile));
     89            AbacID = new Identity(new File(certFile));
    9090        }
    9191        catch (GeneralSecurityException e) {
     
    133133        // our authority.  We could keep the certificate around for other
    134134        // commands to use, but once we tell fedd about it, fedd remembers it.
     135        //
     136        // NB: We have to send both the identity used to sign the credential
     137        // and the credential itself, so that fedd can validate it.
    135138        try {
    136139            Credential c = null;
    137             byte[][] ca = new byte[1][];
     140            byte[][] ca = new byte[2][];
    138141
     142            ca[0] = AbacID.getCertificate().getEncoded(); // Identity
    139143            c = delegate(AbacID, newLabels.getFedid());
    140             ca[0] = c.cert().getEncoded();
     144            ca[1] = c.cert().getEncoded(); // Credential
    141145            createReq.setCredential(ca);
     146            System.err.println(c);
    142147        }
    143148        catch (GeneralSecurityException e) {
Note: See TracChangeset for help on using the changeset viewer.