Plasma.AuthorizationManager

KDE 4.7 PyKDE API Reference

- KDE's Python API

# AuthorizationManager Class Reference

`from PyKDE4.plasma import *`

Inherits: QObject
Namespace: Plasma

## Detailed Description

AuthorizationManager plasma/authorizationmanager.h <Plasma/AccessManager>

Allows authorization of access to plasma services.

This is the class where every message to or from another machine passes through. It's responsibilities are: - creating/keeping a credentials used for message signing. - verifying credentials of incoming messages. - testing whether or not the sender is allowed to access the requested resource by testing the request to a set of rules. - allowing the shell to respond to a remote request that doesn't match any of the rules that are in effect. Besides internal use in libplasma, the only moment you'll need to access this class is when you implement a plasma shell.

Since:
  4.4

## Enumerations
AuthorizationPolicy | { DenyAll, TrustedOnly, PinPairing, Custom }
## Signals
| readyForRemoteAccess ()
## Methods
| __init__ (self)
| setAuthorizationInterface (self, Plasma.AuthorizationInterface interface)
| setAuthorizationPolicy (self, Plasma.AuthorizationManager.AuthorizationPolicy policy)
## Static Methods
Plasma.AuthorizationManager | self ()

## Signal Documentation

readyForRemoteAccess | ( |  | ) |

fires when the AuthorizationManager is ready for accesssing remote plasmoids, meaning the private key has been unlocked by the user.

Signal syntax:
  `QObject.connect(source, SIGNAL("readyForRemoteAccess()"), target_slot)`

## Method Documentation

__init__ | ( |  | self ) |

setAuthorizationInterface | ( | self, |
|  | Plasma.AuthorizationInterface | interface
| ) |  |  |

Register an implementation of AuthorizationInterface. Use this to make your shell handle authorization requests. This can only be set once to avoid that malicious plugins can change this.

setAuthorizationPolicy | ( | self, |
|  | Plasma.AuthorizationManager.AuthorizationPolicy | policy
| ) |  |  |

Set a policy used for authorizing incoming connections. You can either use one of the included policies, Default is to deny all incoming connections. This can only be set once to avoid that malicious plugins can change this. This means that you should ALWAYS call this function in any plasma shell, even if you like to use the default DenyAll policy.

## Static Method Documentation

Plasma.AuthorizationManager self | ( |  | ) |

Singleton pattern accessor.

## Enumeration Documentation

AuthorizationPolicy

Enumerator:

  DenyAll = 0 |
  TrustedOnly = 1 |
  PinPairing = 2 |
  Custom = 256 |