LDAP Account Manager

Uploader
in package

Creates LDAP accounts for file upload.

Tags
author

Roland Gruber

Table of Contents

TIME_LIMIT  = 10
$accounts  : mixed
$data  : mixed
$endTime  : mixed
$type  : mixed
__construct()  : mixed
Constructor
cleanSession()  : mixed
doUpload()  : string
Start or continues the file upload.
buildUploadStatus()  : string
Returns the upload status as JSON.
continueUpload()  : string
Continues to upload accounts.
createPDF()  : string
Creates the PDF files.
deleteOldEntryIfNeeded()  : array<string|int, mixed>
Deletes an existing entry if overwrite option is used.
runModulePostActions()  : array<string|int, mixed>
Runs a single post create action by modules.
runPostActions()  : string
Performs any post create actions by modules.
securityCheck()  : mixed
Checks for security violations and stops processing if needed.
startUpload()  : string
Starts the file upload.
uploadEntry()  : mixed
Performs the upload of a single LDAP entry.

Constants

TIME_LIMIT

public mixed TIME_LIMIT = 10

Properties

$accounts

private mixed $accounts = null

$data

private mixed $data = null

$type

private mixed $type = null

Methods

cleanSession()

public static cleanSession() : mixed
Return values
mixed

doUpload()

Start or continues the file upload.

public doUpload() : string
Return values
string

JSON of upload status

buildUploadStatus()

Returns the upload status as JSON.

private buildUploadStatus(number $accountsProgress[, string $accountsFinished = false ][, string $postActionsTitle = '' ], number $postActionsProgress[, string $postActionsFinished = false ], number $pdfProgress) : string
Parameters
$accountsProgress : number

progress for LDAP entries

$accountsFinished : string = false

all entries in LDAP

$postActionsTitle : string = ''

title for current post action

$postActionsProgress : number

progress for post actions

$postActionsFinished : string = false

post actions finished

$pdfProgress : number

PDF creation progress

Return values
string

JSON status

continueUpload()

Continues to upload accounts.

private continueUpload() : string
Return values
string

JSON of upload status

createPDF()

Creates the PDF files.

private createPDF() : string
Return values
string

JSON of upload status

deleteOldEntryIfNeeded()

Deletes an existing entry if overwrite option is used.

private deleteOldEntryIfNeeded(string $dn, array<string|int, mixed> $attributes) : array<string|int, mixed>
Parameters
$dn : string

DN

$attributes : array<string|int, mixed>

attribute list

Return values
array<string|int, mixed>

list of error messages

runModulePostActions()

Runs a single post create action by modules.

private runModulePostActions() : array<string|int, mixed>
Return values
array<string|int, mixed>

status array

runPostActions()

Performs any post create actions by modules.

private runPostActions() : string
Return values
string

JSON of upload status

securityCheck()

Checks for security violations and stops processing if needed.

private securityCheck() : mixed
Return values
mixed

startUpload()

Starts the file upload.

private startUpload() : string
Return values
string

JSON of upload status

uploadEntry()

Performs the upload of a single LDAP entry.

private uploadEntry(int $position) : mixed
Parameters
$position : int

position in $this->accounts.

Return values
mixed

Search results