blob: 14104464e29e6a19d07a0d5e8bfae9f704da20ec [file] [log] [blame]
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<!-- Generated by Apache Maven Doxia Site Renderer 1.6 at 12 Dec 2015 -->
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<title>Apache Rampart &#x2013; </title>
<style type="text/css" media="all">
@import url("./css/maven-base.css");
@import url("./css/maven-theme.css");
@import url("./css/site.css");
</style>
<link rel="stylesheet" href="./css/print.css" type="text/css" media="print" />
<meta name="Date-Revision-yyyymmdd" content="20151212" />
<meta http-equiv="Content-Language" content="en" />
</head>
<body class="composite">
<div id="banner">
<a href="images/apache-rampart-logo.jpg" id="bannerLeft">
Apache Rampart
</a>
<a href="http://www.apache.org" id="bannerRight">
<img src="http://www.apache.org/images/asf_logo_wide.png" alt="$alt" />
</a>
<div class="clear">
<hr/>
</div>
</div>
<div id="breadcrumbs">
<div class="xleft">
<span id="publishDate">Last Published: 12 Dec 2015</span>
&nbsp;| <span id="projectVersion">Version: 1.6.3</span>
</div>
<div class="xright"> <a href="../core/" title="Apache Axis2/Java">Apache Axis2/Java</a>
</div>
<div class="clear">
<hr/>
</div>
</div>
<div id="leftColumn">
<div id="navcolumn">
<h5>Apache Rampart</h5>
<ul>
<li class="none">
<a href="index.html" title="Home">Home</a>
</li>
<li class="expanded">
<a href="javascript:void(0)" title="Downloads">Downloads</a>
<ul>
<li class="none">
<a href="download.html" title="Releases">Releases</a>
</li>
<li class="none">
<a href="svn.html" title="Source Code">Source Code</a>
</li>
</ul>
</li>
<li class="expanded">
<a href="javascript:void(0)" title="Release Notes">Release Notes</a>
<ul>
<li class="none">
<a href="release-notes/1.6.1.html" title="1.6.1">1.6.1</a>
</li>
<li class="none">
<a href="release-notes/1.6.2.html" title="1.6.2">1.6.2</a>
</li>
<li class="none">
<a href="release-notes/1.6.3.html" title="1.6.3">1.6.3</a>
</li>
</ul>
</li>
</ul>
<h5>Documentation</h5>
<ul>
<li class="none">
<strong>Getting Started</strong>
</li>
<li class="none">
<a href="samples.html" title="Samples">Samples</a>
</li>
<li class="none">
<a href="http://wiki.apache.org/ws/FrontPage/Rampart/FAQ" class="externalLink" title="FAQ">FAQ</a>
</li>
<li class="none">
<a href="rampartconfig-guide.html" title="Rampart Configuration">Rampart Configuration</a>
</li>
<li class="none">
<a href="setting-up-sts.html" title="STS Configuration">STS Configuration</a>
</li>
<li class="none">
<a href="developer-guide.html" title="Developer Guide">Developer Guide</a>
</li>
<li class="none">
<a href="siteHowTo.html" title="Build the Site">Build the Site</a>
</li>
</ul>
<h5>Resources</h5>
<ul>
<li class="none">
<a href="articles.html" title="Articles">Articles</a>
</li>
<li class="none">
<a href="specifications.html" title="Specifications">Specifications</a>
</li>
<li class="none">
<a href="apidocs/index.html" title="Online Javadocs">Online Javadocs</a>
</li>
</ul>
<h5>Project Information</h5>
<ul>
<li class="none">
<a href="team-list.html" title="Project Team">Project Team</a>
</li>
<li class="none">
<a href="http://issues.apache.org/jira/browse/Rampart" class="externalLink" title="Issue Tracking">Issue Tracking</a>
</li>
<li class="none">
<a href="mail-lists.html" title="Mailing Lists">Mailing Lists</a>
</li>
<li class="none">
<a href="http://svn.apache.org/viewvc/axis/axis2/java/rampart/" class="externalLink" title="Source Code">Source Code</a>
</li>
<li class="none">
<a href="http://www.apache.org/licenses/" class="externalLink" title="License">License</a>
</li>
<li class="none">
<a href="http://www.apache.org/foundation/sponsorship.html" class="externalLink" title="Sponsorship">Sponsorship</a>
</li>
<li class="none">
<a href="http://www.apache.org/foundation/thanks.html" class="externalLink" title="Thanks">Thanks</a>
</li>
<li class="none">
<a href="http://www.apache.org/security/" class="externalLink" title="Security">Security</a>
</li>
</ul>
<a href="http://maven.apache.org/" title="Built by Maven" class="poweredBy">
<img class="poweredBy" alt="Built by Maven" src="./images/logos/maven-feather.png" />
</a>
</div>
</div>
<div id="bodyColumn">
<div id="contentBox">
<html xmlns="http://www.w3.org/1999/xhtml">
<h1>Rampart Quick Start Guide</h1>
<div class="section">
<h3><a name="Installing_Rampart_module_in_Axis2"></a>Installing Rampart module in Axis2</h3>
<p>Steps to install</p>
<ol style="list-style-type: decimal">
<li>If you haven't installed Axis2, then download and extract the standard binary distribution. Make sure you have set the AXIS2_HOME environment variable</li>
<li>Run ant from the &quot;samples&quot; directory to copy the required libraries and modules to relevant directories in AXIS2_HOME.</li>
</ol>
<p></p>
</div>
<div class="section">
<h3><a name="Engaging_Rampart"></a>Engaging Rampart</h3>
<p>When securing a SOAP message, the sender must know the security actions to be performed on the message and the receiver must know enough details to process and validate the security of the message. Therefore when using Rampart with Axis2, it must be engaged at both ends.</p>
<p>Observe how module has been engaged in server side by opening samples/policy/sample01/services.xml. The following line has engaged the module.</p>
<p>Engaging Rampart at client side is done programatically as follows.</p>
<div>
<pre>
ServiceClient client = new ServiceClient(ctx, null);
client.engageModule(&quot;rampart&quot;);
</pre></div>
</div>
<div class="section">
<h3><a name="Understanding_policy"></a>Understanding policy</h3>
<p>WS-Security Policy can be used to indicate what security actions that needs be performed on SOAP messages and and what actions should be validated. The file 'samples/policy/sample01/policy.xml' configures Rampart to add Username Token with Timestamp to this message. The element &lt;RampartConfig&gt; in policy.xml defines Rampart specific configurations. </p>
<p>Policy at serverside is included in samples/policy/sample01/services.xml file. This configures Rampart module at serverside to validate the message for Username Token an Timestamp.</p>
<p>More details on RampartConfig can be found <a href="rampartconfig-guide.html">here</a>.</p>
</div>
<div class="section">
<h3><a name="Viewing_the_Message_on_wire"></a>Viewing the Message on wire</h3>
<p>It is interesting to view the secured SOAP message on the wire using TCP monitor. Change the &quot;client.port&quot; property in samples/policy/build.xml file to the listening port of TCP monitor. This will send all the messages through TCP monitor when you execute the ant script. Observe the &lt;wsse:Security&gt; header in the SOAP message.</p>
</div>
</html>
</div>
</div>
<div class="clear">
<hr/>
</div>
<div id="footer">
<div class="xright">
Copyright &#169; 2005&#x2013;2015
<a href="http://www.apache.org">Apache Software Foundation</a>.
All rights reserved.
</div>
<div class="clear">
<hr/>
</div>
</div>
</body>
</html>