Skip to content

Unused $refNode in EncryptBody method #60

@edomato

Description

@edomato

wse-php/src/WSSESoap.php

Lines 438 to 447 in c9611f5

$refNode = $encNode->firstChild;
while ($refNode && $refNode->nodeType != XML_ELEMENT_NODE) {
$refNode = $refNode->nextSibling;
}
if ($refNode) {
$refNode = $refNode->nextSibling;
}
if ($this->addEncryptedKey($encNode, $enc, $token)) {
$this->AddReference($enc->encKey, $guid);
}

The $refNode variable is not used on this method, even more, I couldn't find the use of this method anywhere.

It seems there's two way to encrypt the Body, this mentioned method and the encryptSoapDoc method which can also encrypt the Signature.

So, why thereś two way to do the same thing?, any advantage of one over the other?, and what about the unused variable? 😄

Greets and thanks.
Ernesto

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions