Details
-
Improvement
-
Status: Resolved
-
Minor
-
Resolution: Fixed
-
None
-
None
-
None
Description
Hi,
the attached mediator can be used to validate HTTP Basic Authentication headers within a try block.
HereĀ“s an example usage:
<try>
<sequence>
<class name="de.subnatural.synapse.BasicAuthenticationMediator">
<property name="reqUsername" value="bob"/>
<property name="reqPassword" value="ross"/>
</class>
</sequence>
<onError>
<makefault>
<code value="tns:Receiver" xmlns:tns="http://www.w3.org/2003/05/soap-envelope"/>
<reason value="Authorization failed!"/>
</makefault>
<send/>
</onError>
</try>
Feel free to change package name etc. if you would like to include it as a standard mediator.
Cheers,
Michael