EDataServer.SourceSecurity

g EDataServer.SourceExtension EDataServer.SourceExtension EDataServer.SourceSecurity EDataServer.SourceSecurity EDataServer.SourceExtension->EDataServer.SourceSecurity GObject.Object GObject.Object GObject.Object->EDataServer.SourceExtension

Subclasses:

None

Methods

Inherited:

EDataServer.SourceExtension (4), GObject.Object (37)

Structs:

GObject.ObjectClass (5)

dup_method ()

get_method ()

get_secure ()

set_method (method)

set_secure (secure)

Virtual Methods

Inherited:

GObject.Object (7)

Properties

Inherited:

EDataServer.SourceExtension (1)

Name

Type

Flags

Short Description

method

str

r/w/c/en

Security method

secure

bool

r/w/en

Secure the network connection

Signals

Inherited:

GObject.Object (1)

Fields

Inherited:

GObject.Object (1)

Name

Type

Access

Description

parent

EDataServer.SourceExtension

r

Class Details

class EDataServer.SourceSecurity(**kwargs)
Bases:

EDataServer.SourceExtension

Abstract:

No

Structure:

EDataServer.SourceSecurityClass

Contains only private data that should be read and manipulated using the functions below.

New in version 3.6.

dup_method()
Returns:

a newly-allocated copy of EDataServer.SourceSecurity :method

Return type:

str

Thread-safe variation of EDataServer.SourceSecurity.get_method(). Use this function when accessing self from multiple threads.

The returned string should be freed with GLib.free() when no longer needed.

New in version 3.6.

get_method()
Returns:

the method used to establish a secure network connection

Return type:

str

Returns the method used to establish a secure network connection to a remote account. There are no pre-defined method names; backends are free to set this however they wish. If a secure connection is not desired, the convention is to set EDataServer.SourceSecurity :method to “none”.

New in version 3.6.

get_secure()
Returns:

whether a secure network connection is desired

Return type:

bool

This is a convenience function which returns whether a secure network connection is desired, regardless of the method used. This relies on the convention of setting EDataServer.SourceSecurity :method to “none” when a secure network connection is not desired.

New in version 3.6.

set_method(method)
Parameters:

method (str or None) – security method, or None

Sets the method used to establish a secure network connection to a remote account. There are no pre-defined method names; backends are free to set this however they wish. If a secure connection is not desired, the convention is to set EDataServer.SourceSecurity :method to “none”. In keeping with that convention, EDataServer.SourceSecurity :method will be set to “none” if method is None or an empty string.

New in version 3.6.

set_secure(secure)
Parameters:

secure (bool) – whether a secure network connection is desired

This function provides a simpler way to set EDataServer.SourceSecurity :method when using a secure network connection is a yes or no option and the exact method name is unimportant. If secure is False, the EDataServer.SourceSecurity :method property is set to “none”. If secure is True, the function assumes the backend will use Transport Layer Security and sets the EDataServer.SourceSecurity :method property to “tls”.

New in version 3.6.

Property Details

EDataServer.SourceSecurity.props.method
Name:

method

Type:

str

Default Value:

'none'

Flags:

READABLE, WRITABLE, CONSTRUCT, EXPLICIT_NOTIFY

Security method

EDataServer.SourceSecurity.props.secure
Name:

secure

Type:

bool

Default Value:

False

Flags:

READABLE, WRITABLE, EXPLICIT_NOTIFY

Secure the network connection