PHP Класс XMLSecurityDSig

Показать файл Открыть проект Примеры использования класса

Открытые свойства

Свойство Тип Описание
$idKeys
$idNS
$sigNode

Открытые методы

Метод Описание
__construct ( )
add509Cert ( $cert, $isPEMFormat = true, $isURL = false, $options = null )
addObject ( $data, $mimetype = null, $encoding = null )
addReference ( $node, $algorithm, $arTransforms = null, $options = null )
addReferenceList ( $arNodes, $algorithm, $arTransforms = null, $options = null )
appendCert ( )
appendKey ( $objKey, $parent = null )
appendSignature ( $parentNode, $insertBefore = false )
appendToKeyInfo ( DOMNode $node ) : DOMNode This function appends a node to the KeyInfo.
auxKeyInfo ( $parentRef, $xpath = null )
calculateDigest ( $digestAlgorithm, $data, $encode = true )
canonicalizeSignedInfo ( )
createNewSignNode ( $name, $value = null )
generateGUID ( $prefix = 'pfx' )
get509XCert ( $cert, $isPEMFormat = true )
getRefIDs ( )
getRefNodeID ( $refNode )
getValidatedNodes ( ) * This function retrieves an associative array of the validated nodes.
insertSignature ( $node, $beforeNode = null ) : DOMNode This function inserts the signature element.
locateKey ( $node = null )
locateSignature ( $objDoc, $pos )
processRefNode ( $refNode )
processTransforms ( $refNode, $objData, $includeCommentNodes = true )
setCanonicalMethod ( $method )
sign ( $objKey, $appendToNode = null )
signData ( $objKey, $data )
staticAdd509Cert ( $parentRef, $cert, $isPEMFormat = true, $isURL = false, $xpath = null, $options = null )
staticGet509XCerts ( $certs, $isPEMFormat = true )
validateDigest ( $refNode, $data )
validateReference ( )
verify ( $objKey )

Приватные методы

Метод Описание
addRefInternal ( $sinfoNode, $node, $algorithm, $arTransforms = null, $options = null )
canonicalizeData ( $node, $canonicalmethod, $arXPath = null, $prefixList = null )
getXPathObj ( )
resetXPathObj ( )

Описание методов

__construct() публичный Метод

public __construct ( )

add509Cert() публичный Метод

public add509Cert ( $cert, $isPEMFormat = true, $isURL = false, $options = null )

addObject() публичный Метод

public addObject ( $data, $mimetype = null, $encoding = null )

addReference() публичный Метод

public addReference ( $node, $algorithm, $arTransforms = null, $options = null )

addReferenceList() публичный Метод

public addReferenceList ( $arNodes, $algorithm, $arTransforms = null, $options = null )

appendCert() публичный Метод

public appendCert ( )

appendKey() публичный Метод

public appendKey ( $objKey, $parent = null )

appendSignature() публичный Метод

public appendSignature ( $parentNode, $insertBefore = false )

appendToKeyInfo() публичный Метод

The KeyInfo element will be created if one does not exist in the document.
public appendToKeyInfo ( DOMNode $node ) : DOMNode
$node DOMNode The node to append to the KeyInfo.
Результат DOMNode The KeyInfo element node

auxKeyInfo() статический публичный Метод

static public auxKeyInfo ( $parentRef, $xpath = null )

calculateDigest() публичный Метод

public calculateDigest ( $digestAlgorithm, $data, $encode = true )

canonicalizeSignedInfo() публичный Метод

createNewSignNode() публичный Метод

public createNewSignNode ( $name, $value = null )

generateGUID() статический публичный Метод

static public generateGUID ( $prefix = 'pfx' )

get509XCert() статический публичный Метод

static public get509XCert ( $cert, $isPEMFormat = true )

getRefIDs() публичный Метод

public getRefIDs ( )

getRefNodeID() публичный Метод

public getRefNodeID ( $refNode )

getValidatedNodes() публичный Метод

The array will contain the id of the referenced node as the key and the node itself as the value. Returns: An associative array of validated nodes or null if no nodes have been validated.
public getValidatedNodes ( )

insertSignature() публичный Метод

The signature element will be appended to the element, unless $beforeNode is specified. If $beforeNode is specified, the signature element will be inserted as the last element before $beforeNode.
public insertSignature ( $node, $beforeNode = null ) : DOMNode
$node The node the signature element should be inserted into.
$beforeNode The node the signature element should be located before.
Результат DOMNode The signature element node

locateKey() публичный Метод

public locateKey ( $node = null )

locateSignature() публичный Метод

public locateSignature ( $objDoc, $pos )

processRefNode() публичный Метод

public processRefNode ( $refNode )

processTransforms() публичный Метод

public processTransforms ( $refNode, $objData, $includeCommentNodes = true )

setCanonicalMethod() публичный Метод

public setCanonicalMethod ( $method )

sign() публичный Метод

public sign ( $objKey, $appendToNode = null )

signData() публичный Метод

public signData ( $objKey, $data )

staticAdd509Cert() статический публичный Метод

static public staticAdd509Cert ( $parentRef, $cert, $isPEMFormat = true, $isURL = false, $xpath = null, $options = null )

staticGet509XCerts() статический публичный Метод

static public staticGet509XCerts ( $certs, $isPEMFormat = true )

validateDigest() публичный Метод

public validateDigest ( $refNode, $data )

validateReference() публичный Метод

public validateReference ( )

verify() публичный Метод

public verify ( $objKey )

Описание свойств

$idKeys публичное свойство

public $idKeys

$idNS публичное свойство

public $idNS

$sigNode публичное свойство

public $sigNode