web/lib/Zend/InfoCard/Xml/EncryptedData/XmlEnc.php
changeset 807 877f952ae2bd
parent 207 621fa6caec0c
equal deleted inserted replaced
805:5e7a0fedabdf 807:877f952ae2bd
    13  * to license@zend.com so we can send you a copy immediately.
    13  * to license@zend.com so we can send you a copy immediately.
    14  *
    14  *
    15  * @category   Zend
    15  * @category   Zend
    16  * @package    Zend_InfoCard
    16  * @package    Zend_InfoCard
    17  * @subpackage Zend_InfoCard_Xml
    17  * @subpackage Zend_InfoCard_Xml
    18  * @copyright  Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com)
    18  * @copyright  Copyright (c) 2005-2012 Zend Technologies USA Inc. (http://www.zend.com)
    19  * @license    http://framework.zend.com/license/new-bsd     New BSD License
    19  * @license    http://framework.zend.com/license/new-bsd     New BSD License
    20  * @version    $Id: XmlEnc.php 20096 2010-01-06 02:05:09Z bkarwin $
    20  * @version    $Id: XmlEnc.php 24593 2012-01-05 20:35:02Z matthew $
    21  */
    21  */
    22 
    22 
    23 /**
    23 /**
    24  * Zend_InfoCard_Xml_EncryptedData/Abstract.php
    24  * Zend_InfoCard_Xml_EncryptedData/Abstract.php
    25  */
    25  */
    29  * An XmlEnc formatted EncryptedData XML block
    29  * An XmlEnc formatted EncryptedData XML block
    30  *
    30  *
    31  * @category   Zend
    31  * @category   Zend
    32  * @package    Zend_InfoCard
    32  * @package    Zend_InfoCard
    33  * @subpackage Zend_InfoCard_Xml
    33  * @subpackage Zend_InfoCard_Xml
    34  * @copyright  Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com)
    34  * @copyright  Copyright (c) 2005-2012 Zend Technologies USA Inc. (http://www.zend.com)
    35  * @license    http://framework.zend.com/license/new-bsd     New BSD License
    35  * @license    http://framework.zend.com/license/new-bsd     New BSD License
    36  */
    36  */
    37 class Zend_InfoCard_Xml_EncryptedData_XmlEnc extends Zend_InfoCard_Xml_EncryptedData_Abstract
    37 class Zend_InfoCard_Xml_EncryptedData_XmlEnc extends Zend_InfoCard_Xml_EncryptedData_Abstract
    38 {
    38 {
    39 
    39 
    50         list(,$cipherdata) = $this->xpath("//enc:CipherData");
    50         list(,$cipherdata) = $this->xpath("//enc:CipherData");
    51 
    51 
    52         if(!($cipherdata instanceof Zend_InfoCard_Xml_Element)) {
    52         if(!($cipherdata instanceof Zend_InfoCard_Xml_Element)) {
    53             throw new Zend_InfoCard_Xml_Exception("Unable to find the enc:CipherData block");
    53             throw new Zend_InfoCard_Xml_Exception("Unable to find the enc:CipherData block");
    54         }
    54         }
    55 
    55         $cipherdata->registerXPathNamespace('enc', 'http://www.w3.org/2001/04/xmlenc#');
    56         list(,$ciphervalue) = $cipherdata->xpath("//enc:CipherValue");
    56         list(,$ciphervalue) = $cipherdata->xpath("//enc:CipherValue");
    57 
    57 
    58         if(!($ciphervalue instanceof Zend_InfoCard_Xml_Element)) {
    58         if(!($ciphervalue instanceof Zend_InfoCard_Xml_Element)) {
    59             throw new Zend_InfoCard_Xml_Exception("Unable to fidn the enc:CipherValue block");
    59             throw new Zend_InfoCard_Xml_Exception("Unable to fidn the enc:CipherValue block");
    60         }
    60         }