Class: WSS4R::Security::Util::SOAPParser
- Inherits:
-
Object
- Object
- WSS4R::Security::Util::SOAPParser
- Defined in:
- lib/wss4r/security/util/soap_parser.rb
Constant Summary collapse
- BODY =
"/env:Envelope/env:Body"- ENVELOPE =
"/env:Envelope"- HEADER =
"/env:Envelope/env:Header"- KEY_IDENTIFIER =
"//wsse:SecurityTokenReference//wsse:KeyIdentifier"- SECURITY =
"/env:Envelope/env:Header/wsse:Security"- CIPHER_DATA =
"//xenc:CipherData//xenc:CipherValue"- CIPHER_VALUE =
"//xenc:CipherValue"- SIGNED_INFO =
"//ds:SignedInfo"- ENCRYPTION_METHOD =
"//xenc:EncryptionMethod"- KEY_INFO =
"//ds:KeyInfo"- REFERENCE_LIST =
"//env:Envelope/env:Header/wsse:Security/xenc:EncryptedKey/xenc:ReferenceList"- SIGNATURE =
"/env:Envelope/env:Header/wsse:Security/ds:Signature"- ENCRYPTED_KEY =
"/env:Envelope/env:Header/wsse:Security/xenc:EncryptedKey"- @@document =
nil- @@prefix =
nil- @@soap_ns =
nil- @@soap_prefix =
nil
Class Method Summary collapse
- .document ⇒ Object
- .document=(value) ⇒ Object
- .element(element, type) ⇒ Object
- .part(type) ⇒ Object
- .soap_ns ⇒ Object
- .soap_ns=(ns) ⇒ Object
- .soap_prefix ⇒ Object
- .soap_prefix=(prefix) ⇒ Object
Class Method Details
.document ⇒ Object
25 26 27 |
# File 'lib/wss4r/security/util/soap_parser.rb', line 25 def self.document() @@document end |
.document=(value) ⇒ Object
29 30 31 32 33 34 35 36 37 38 39 |
# File 'lib/wss4r/security/util/soap_parser.rb', line 29 def self.document=(value) @@document = value prefix = @@document.root().prefix() #set the prefix to env or soap BODY.gsub!("env:", prefix+":") ENVELOPE.gsub!("env:", prefix+":") HEADER.gsub!("env:", prefix+":") SECURITY.gsub!("env:", prefix+":") REFERENCE_LIST.gsub!("env:", prefix+":") SIGNATURE.gsub!("env:", prefix+":") ENCRYPTED_KEY.gsub!("env:", prefix+":") end |
.element(element, type) ⇒ Object
58 59 60 61 |
# File 'lib/wss4r/security/util/soap_parser.rb', line 58 def self.element(element, type) result = @@document.select_element(element, type) result end |
.part(type) ⇒ Object
53 54 55 56 |
# File 'lib/wss4r/security/util/soap_parser.rb', line 53 def self.part(type) element = @@document.select(type) element end |
.soap_ns ⇒ Object
47 48 49 |
# File 'lib/wss4r/security/util/soap_parser.rb', line 47 def self.soap_ns() @@soap_ns end |
.soap_ns=(ns) ⇒ Object
41 42 43 |
# File 'lib/wss4r/security/util/soap_parser.rb', line 41 def self.soap_ns=(ns) @@soap_ns = ns end |
.soap_prefix ⇒ Object
50 51 52 |
# File 'lib/wss4r/security/util/soap_parser.rb', line 50 def self.soap_prefix() @@soap_prefix end |
.soap_prefix=(prefix) ⇒ Object
44 45 46 |
# File 'lib/wss4r/security/util/soap_parser.rb', line 44 def self.soap_prefix=(prefix) @@soap_prefix = prefix end |