Package buildbot :: Package process :: Package users :: Module users
[frames] | no frames]

Module users

source code

Functions
 
createUserObject(*args, **kwargs)
Take a Change author and source and translate them into a User Object, storing the user in master.db, or returning None if the src is not specified.
source code
 
getUserContact(master, contact_type=None, uid=None)
This is a simple getter function that returns a user attribute that matches the contact_type argument, or returns None if no uid/match is found.
source code
 
encrypt(passwd)
Encrypts the incoming password after adding some salt to store it in the database.
source code
 
check_passwd(guess, passwd)
Tests to see if the guess, after salting and hashing, matches the passwd from the database.
source code
Variables
  srcs = ['git', 'svn', 'hg', 'cvs', 'darcs', 'bzr']
  salt_len = 8
  __package__ = 'buildbot.process.users'
Function Details

createUserObject(*args, **kwargs)

source code 

Take a Change author and source and translate them into a User Object, storing the user in master.db, or returning None if the src is not specified.

Parameters:
  • master (master.Buildmaster instance) - link to Buildmaster for database operations
  • authors (string or status.web.authz instance) - Change author if string or Authz instance
  • src (string) - source from which the User Object will be created
Decorators:
  • @defer.deferredGenerator

getUserContact(master, contact_type=None, uid=None)

source code 

This is a simple getter function that returns a user attribute that matches the contact_type argument, or returns None if no uid/match is found.

Parameters:
  • master (BuildMaster instance) - BuildMaster used to query the database
  • contact_type (string) - type of contact attribute to look for in in a given user, such as 'email' or 'nick'
  • uid (integer) - user that is searched for the contact_type match
Returns:
string of contact information or None via deferred

encrypt(passwd)

source code 

Encrypts the incoming password after adding some salt to store it in the database.

Parameters:
  • passwd (string) - password portion of user credentials
Returns:
encrypted/salted string

check_passwd(guess, passwd)

source code 

Tests to see if the guess, after salting and hashing, matches the passwd from the database.

Parameters:
  • guess - incoming password trying to be used for authentication
  • passwd - already encrypted password from the database
Returns:
boolean