1111 afp , aio , antivirus , array , audit , backup , cache , cli , config , connection , ctera_migrate ,
1212 dedup , directoryservice , drive , files , firmware , ftp , groups , licenses , login ,
1313 logs , mail , network , nfs , ntp , power , remote , rsync , ransom_protect , services ,
14- shares , shell , smb , snmp , ssh , ssl , support , sync , syslog , tasks , telnet ,
14+ shares , shell , smb , snmp , ssh , ssl , statistics , support , sync , syslog , tasks , telnet ,
1515 timezone , users , volumes ,
1616)
1717
@@ -27,6 +27,7 @@ def __init__(self, edge, Portal):
2727 else :
2828 self .migrate = edge .default .clone (clients .Migrate , EndpointBuilder .new (edge .base , '/migration/rest/v1' ))
2929 self .api = edge .default .clone (clients .API , EndpointBuilder .new (edge .base , '/admingui/api' ))
30+ self .stats = edge .default .clone (clients .JSON , EndpointBuilder .new (edge .base , '/stats' ))
3031 self .io = IO (edge )
3132
3233
@@ -108,6 +109,7 @@ def __init__(self, host=None, port=None, https=True, Portal=None, *, base=None):
108109 self .snmp = snmp .SNMP (self )
109110 self .ssh = ssh .SSH (self )
110111 self .ssl = modules .initialize (ssl .SSLModule , self )
112+ self .statistics = statistics .Statistics (self )
111113 self .support = support .Support (self )
112114 self .sync = sync .Sync (self )
113115 self .syslog = syslog .Syslog (self )
@@ -151,8 +153,14 @@ def initialized(self):
151153 def test (self ):
152154 return connection .test (self )
153155
154- def sso (self , ticket ):
155- """ Login using Single Sign On"""
156+ def sso (self , ticket , session ):
157+ """
158+ Single Sign on from CTERA Portal to CTERA Edge Filer.
159+
160+ :param str ticket: SSO Ticket
161+ :param dict session: CTERA Portal Session Cookie
162+ """
163+ self .default .cookie_jar .update_cookies (session , self .default .baseurl )
156164 self ._login_object .sso (ticket )
157165 self .session ().start_session (self )
158166
@@ -164,5 +172,5 @@ def _omit_fields(self):
164172 return super ()._omit_fields + ['afp' , 'aio' , 'array' , 'audit' , 'antivirus' , 'backup' , 'cache' , 'cli' , 'config' , 'ctera_migrate' ,
165173 'dedup' , 'directoryservice' , 'drive' , 'files' , 'firmware' , 'ftp' , 'groups' , 'licenses' , 'logs' ,
166174 'mail' , 'network' , 'nfs' , 'ntp' , 'power' , 'ransom_protect' , 'rsync' , 'services' , 'shares' , 'shell' ,
167- 'smb' , 'snmp' , 'ssh' , 'ssl' , 'support' , 'sync' , 'syslog' , 'tasks' , 'telnet' , 'timezone ' ,
168- 'users' , 'volumes' ]
175+ 'smb' , 'snmp' , 'ssh' , 'ssl' , 'statistics' , ' support' , 'sync' , 'syslog' , 'tasks' , 'telnet' ,
176+ 'timezone' , ' users' , 'volumes' ]
0 commit comments