Changeset 822d31b


Ignore:
Timestamp:
Nov 30, 2010 11:54:31 AM (14 years ago)
Author:
Ted Faber <faber@…>
Branches:
axis_example, compt_changes, info-ops, master
Children:
c002cb2
Parents:
78f2668
Message:

fix legacy mode

Location:
fedd/federation
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • fedd/federation/authorizer.py

    r78f2668 r822d31b  
    170170        return rv
    171171
    172     def save(self, fn):
    173         f = open(fn, "w")
    174         pickle.dump(self, f)
    175         f.close()
    176 
    177     def load(self, fn):
    178         f = open(fn, "r")
    179         a = pickle.load(f)
    180         f.close()
    181         self.attrs = a.attrs
    182         self.globals = a.globals
     172    def save(self, fn=None):
     173        if fn:
     174            f = open(fn, "w")
     175            pickle.dump(self, f)
     176            f.close()
     177
     178    def load(self, fn=None):
     179        if fn:
     180            f = open(fn, "r")
     181            a = pickle.load(f)
     182            f.close()
     183            self.attrs = a.attrs
     184            self.globals = a.globals
    183185       
    184186
  • fedd/federation/emulab_access.py

    r78f2668 r822d31b  
    534534        for o in owners:
    535535            self.auth.set_attribute(o, allocID)
    536             print "Set delete rights on %s for %s" % (o, allocID)
    537536        self.auth.save()
    538537        try:
  • fedd/federation/experiment_control.py

    r78f2668 r822d31b  
    11501150        else:
    11511151            cert = self.cert_file
    1152             pw = self.cert_pw
     1152            pw = self.cert_pwd
    11531153
    11541154        for tb in allocated.keys():
     
    18491849        # make a protected copy of the access certificate so the experiment
    18501850        # controller can act as the experiment principal.
    1851         if expcert:
     1851        if expcert and self.auth_type != 'legacy':
    18521852            expcert_file = self.make_temp_certfile(expcert, tmpdir)
    18531853            if not expcert_file:
     
    24862486                # If no expcert, try the deallocation as the experiment
    24872487                # controller instance.
    2488                 if expcert:
     2488                if expcert and self.auth_type != 'legacy':
    24892489                    cert_file = self.make_temp_certfile(expcert, tmpdir)
    24902490                    pw = None
    24912491                else:
    24922492                    cert_file = self.cert_file
    2493                     pw = self.cert_pw
     2493                    pw = self.cert_pwd
    24942494
    24952495                # Stop everyone.  NB, wait_for_all waits until a thread starts
Note: See TracChangeset for help on using the changeset viewer.