You are viewing a plain text version of this content. The canonical link for it is here.
Posted to rampart-dev@ws.apache.org by ka...@apache.org on 2007/09/18 11:25:43 UTC

svn commit: r576797 - in /webservices/rampart/trunk/c: include/ samples/secpolicy/scenario5/

Author: kaushalye
Date: Tue Sep 18 02:25:42 2007
New Revision: 576797

URL: http://svn.apache.org/viewvc?rev=576797&view=rev
Log:
Code cleaning

Modified:
    webservices/rampart/trunk/c/include/oxs_asym_ctx.h
    webservices/rampart/trunk/c/include/oxs_axiom.h
    webservices/rampart/trunk/c/include/oxs_buffer.h
    webservices/rampart/trunk/c/include/oxs_c14n.h
    webservices/rampart/trunk/c/include/oxs_cipher.h
    webservices/rampart/trunk/c/include/oxs_constants.h
    webservices/rampart/trunk/c/include/oxs_ctx.h
    webservices/rampart/trunk/c/include/oxs_error.h
    webservices/rampart/trunk/c/include/oxs_key.h
    webservices/rampart/trunk/c/include/oxs_token_binary_security_token.h
    webservices/rampart/trunk/c/include/oxs_x509_cert.h
    webservices/rampart/trunk/c/include/rampart_constants.h
    webservices/rampart/trunk/c/include/rampart_rd_record.h
    webservices/rampart/trunk/c/include/rampart_sec_header_builder.h
    webservices/rampart/trunk/c/include/rampart_timestamp_token.h
    webservices/rampart/trunk/c/samples/secpolicy/scenario5/services.xml

Modified: webservices/rampart/trunk/c/include/oxs_asym_ctx.h
URL: http://svn.apache.org/viewvc/webservices/rampart/trunk/c/include/oxs_asym_ctx.h?rev=576797&r1=576796&r2=576797&view=diff
==============================================================================
--- webservices/rampart/trunk/c/include/oxs_asym_ctx.h (original)
+++ webservices/rampart/trunk/c/include/oxs_asym_ctx.h Tue Sep 18 02:25:42 2007
@@ -35,7 +35,7 @@
 {
 #endif
 
-    /** @defgroup oxs_asym_ctx Message Context
+    /** @defgroup oxs oxs_asym_ctx
      * @ingroup 
      * @{
      */

Modified: webservices/rampart/trunk/c/include/oxs_axiom.h
URL: http://svn.apache.org/viewvc/webservices/rampart/trunk/c/include/oxs_axiom.h?rev=576797&r1=576796&r2=576797&view=diff
==============================================================================
--- webservices/rampart/trunk/c/include/oxs_axiom.h (original)
+++ webservices/rampart/trunk/c/include/oxs_axiom.h Tue Sep 18 02:25:42 2007
@@ -36,6 +36,11 @@
 extern "C"
 {
 #endif
+    /** @defgroup oxs oxs_axiom
+      * @ingroup oxs
+      * @{
+      * @}
+      */
 
     /**
      * Adds an attribute to a particular node

Modified: webservices/rampart/trunk/c/include/oxs_buffer.h
URL: http://svn.apache.org/viewvc/webservices/rampart/trunk/c/include/oxs_buffer.h?rev=576797&r1=576796&r2=576797&view=diff
==============================================================================
--- webservices/rampart/trunk/c/include/oxs_buffer.h (original)
+++ webservices/rampart/trunk/c/include/oxs_buffer.h Tue Sep 18 02:25:42 2007
@@ -37,8 +37,8 @@
 {
 #endif
 
-    /** @defgroup
-     * @ingroup 
+    /** @defgroup oxs oxs_buffer
+     * @ingroup oxs
      * @{
      */
 

Modified: webservices/rampart/trunk/c/include/oxs_c14n.h
URL: http://svn.apache.org/viewvc/webservices/rampart/trunk/c/include/oxs_c14n.h?rev=576797&r1=576796&r2=576797&view=diff
==============================================================================
--- webservices/rampart/trunk/c/include/oxs_c14n.h (original)
+++ webservices/rampart/trunk/c/include/oxs_c14n.h Tue Sep 18 02:25:42 2007
@@ -25,7 +25,7 @@
 
 /**
  * @file oxs_c14n.h
- * @brief
+ * @brief Cannonicalization algo implementation for OMXMLSecurity
  */
 
 #include <axis2_const.h>

Modified: webservices/rampart/trunk/c/include/oxs_cipher.h
URL: http://svn.apache.org/viewvc/webservices/rampart/trunk/c/include/oxs_cipher.h?rev=576797&r1=576796&r2=576797&view=diff
==============================================================================
--- webservices/rampart/trunk/c/include/oxs_cipher.h (original)
+++ webservices/rampart/trunk/c/include/oxs_cipher.h Tue Sep 18 02:25:42 2007
@@ -33,6 +33,13 @@
 {
 #endif
 
+/**
+     * @defgroup oxs_cipher oxs_cipher
+     * @ingroup oxs
+     * @{
+     */
+
+
     /**
      * Get the cipher property  for the given url
      * @env pointer to environment struct

Modified: webservices/rampart/trunk/c/include/oxs_constants.h
URL: http://svn.apache.org/viewvc/webservices/rampart/trunk/c/include/oxs_constants.h?rev=576797&r1=576796&r2=576797&view=diff
==============================================================================
--- webservices/rampart/trunk/c/include/oxs_constants.h (original)
+++ webservices/rampart/trunk/c/include/oxs_constants.h Tue Sep 18 02:25:42 2007
@@ -22,6 +22,17 @@
 extern "C"
 {
 #endif
+    /** @defgroup oxs OMXMLSecurity
+      * @ingroup oxs
+      * @{
+      * @}
+      */
+
+    /**
+     * @defgroup oxs_constants
+     * @ingroup oxs
+     * @{
+     */
 
     /*Default values*/
     /*Key transfer algo*/
@@ -347,7 +358,7 @@
     /*************************************************************************/
 
 
-
+/** @} */
 #ifdef __cplusplus
 }
 #endif

Modified: webservices/rampart/trunk/c/include/oxs_ctx.h
URL: http://svn.apache.org/viewvc/webservices/rampart/trunk/c/include/oxs_ctx.h?rev=576797&r1=576796&r2=576797&view=diff
==============================================================================
--- webservices/rampart/trunk/c/include/oxs_ctx.h (original)
+++ webservices/rampart/trunk/c/include/oxs_ctx.h Tue Sep 18 02:25:42 2007
@@ -35,14 +35,12 @@
 {
 #endif
 
-    /** @defgroup oxs_ctx Message Context
+    /** 
+     * @defgroup oxs_ctx Message Context
      * @ingroup oxs_context
      * @{
      */
 
-    /*TODO We need to change the name oxs_ctx -> oxs_sym_ctx.
-     * The name is sounds too generic as there is another oxs_asym_ctx.
-     * */
 
     typedef enum  {
         OXS_CTX_OPERATION_NONE = 0,
@@ -58,8 +56,6 @@
 
     /** Type name for struct oxs_ctx */
     typedef struct oxs_ctx_t oxs_ctx_t;
-
-
 
     /**
      * Free function of the context

Modified: webservices/rampart/trunk/c/include/oxs_error.h
URL: http://svn.apache.org/viewvc/webservices/rampart/trunk/c/include/oxs_error.h?rev=576797&r1=576796&r2=576797&view=diff
==============================================================================
--- webservices/rampart/trunk/c/include/oxs_error.h (original)
+++ webservices/rampart/trunk/c/include/oxs_error.h Tue Sep 18 02:25:42 2007
@@ -20,6 +20,8 @@
 
 
 /**
+  * @defgroup oxs_error oxs_error
+  * @ingroup oxs
   * @file oxs_error.h
   * @brief Represents an Error occured during the OMXMLSecurity execution 
   */

Modified: webservices/rampart/trunk/c/include/oxs_key.h
URL: http://svn.apache.org/viewvc/webservices/rampart/trunk/c/include/oxs_key.h?rev=576797&r1=576796&r2=576797&view=diff
==============================================================================
--- webservices/rampart/trunk/c/include/oxs_key.h (original)
+++ webservices/rampart/trunk/c/include/oxs_key.h Tue Sep 18 02:25:42 2007
@@ -20,6 +20,7 @@
 
 
 /**
+ *  @defgroup oxs oxs_key
   * @file oxs_key.h
   * @brief represents a Key in OMXMLSecurity 
   */

Modified: webservices/rampart/trunk/c/include/oxs_token_binary_security_token.h
URL: http://svn.apache.org/viewvc/webservices/rampart/trunk/c/include/oxs_token_binary_security_token.h?rev=576797&r1=576796&r2=576797&view=diff
==============================================================================
--- webservices/rampart/trunk/c/include/oxs_token_binary_security_token.h (original)
+++ webservices/rampart/trunk/c/include/oxs_token_binary_security_token.h Tue Sep 18 02:25:42 2007
@@ -21,7 +21,7 @@
 
 /**
   * @file oxs_token_binary_security_token.h
-  * @brief 
+  * @brief <wsse:BinarySecurityToken> related functions
   */
 #include <axis2_util.h>
 #include <axis2_defines.h>
@@ -36,6 +36,7 @@
 
     /**
     * BinarySecurityToken
+    * \brief Create element <wsse:BinarySecurityToken>
     */
     AXIS2_EXTERN axiom_node_t* AXIS2_CALL
     oxs_token_build_binary_security_token_element(const axutil_env_t *env,

Modified: webservices/rampart/trunk/c/include/oxs_x509_cert.h
URL: http://svn.apache.org/viewvc/webservices/rampart/trunk/c/include/oxs_x509_cert.h?rev=576797&r1=576796&r2=576797&view=diff
==============================================================================
--- webservices/rampart/trunk/c/include/oxs_x509_cert.h (original)
+++ webservices/rampart/trunk/c/include/oxs_x509_cert.h Tue Sep 18 02:25:42 2007
@@ -34,8 +34,9 @@
 {
 #endif
 
-    /** @defgroup oxs_x509_cert
-     * @ingroup 
+    /** 
+     * @defgroup oxs_x509_cert
+     * @ingroup oxs 
      * @{
      */
 

Modified: webservices/rampart/trunk/c/include/rampart_constants.h
URL: http://svn.apache.org/viewvc/webservices/rampart/trunk/c/include/rampart_constants.h?rev=576797&r1=576796&r2=576797&view=diff
==============================================================================
--- webservices/rampart/trunk/c/include/rampart_constants.h (original)
+++ webservices/rampart/trunk/c/include/rampart_constants.h Tue Sep 18 02:25:42 2007
@@ -31,6 +31,23 @@
 {
 #endif
 
+/** \mainpage Rampart/C API Documentation
+  *
+  * \section intro_sec Introduction
+  *
+  * This is the API documetation of Apache Rampart/C, which is the
+  * security module for Apache Axis2/C.
+  * It features in many ways to protect SOAP messages exchanged.
+  * This includes SOAP message encryption and signature as specified in WS-Security Specification. 
+  * In addition Apache Rampart/C configurations are based on security policy assertions as per WS-Security Policy specification
+  * <p>We welcome your feedback on this implementation and documentation.
+  * Please send your feedback to <a href="mailto:rampart-c-dev@ws.apache.org">
+  * rampart-c-dev@ws.apache.org</a> 
+  *
+  */
+
+
+
     /*Default values*/
 #define RAMPART_DEFAULT_KT_ALGO OXS_DEFAULT_KT_ALGO_HREF
 #define RAMPART_STR_DEFAULT OXS_STR_DEFAULT

Modified: webservices/rampart/trunk/c/include/rampart_rd_record.h
URL: http://svn.apache.org/viewvc/webservices/rampart/trunk/c/include/rampart_rd_record.h?rev=576797&r1=576796&r2=576797&view=diff
==============================================================================
--- webservices/rampart/trunk/c/include/rampart_rd_record.h (original)
+++ webservices/rampart/trunk/c/include/rampart_rd_record.h Tue Sep 18 02:25:42 2007
@@ -17,8 +17,8 @@
 #ifndef RAMPART_RD_RECORD_H
 #define RAMPART_RD_RECORD_H
 
-/** @defgroup rampart_context
- * @ingroup rampart_context
+/** @defgroup 
+ * @ingroup 
  * @{
  */
 
@@ -30,44 +30,74 @@
 #endif
 
  typedef struct rampart_rd_record_t rampart_rd_record_t;
-/*Create function*/
+/**
+* Create function
+* @param env pointer to environment struct
+* @return return pointer on success otherwise NULL 
+*/
 AXIS2_EXTERN rampart_rd_record_t *AXIS2_CALL
 rampart_rd_record_create(const axutil_env_t *env);
 
-/*Free*/
+/**
+* Free function
+* @param rd_record the record
+* @param env pointer to environment struct
+* @return AXIS2_SUCCESS on success, else AXIS2_FAILURE
+*/
 AXIS2_EXTERN axis2_status_t AXIS2_CALL
 rampart_rd_record_free(rampart_rd_record_t *rd_record,
                   const axutil_env_t *env);
 
 
+/**
+* Get the record ID
+* @param rd_record the record
+* @param env pointer to environment struct
+* @return record ID on success otherwise NULL
+*/
 AXIS2_EXTERN axis2_char_t *AXIS2_CALL
 rampart_rd_record_get_id(
     const rampart_rd_record_t *rd_record,
     const axutil_env_t *env);
 
+/**
+* Get the timestamp
+* @param rd_record the record
+* @param env pointer to environment struct
+* @param
+* @return AXIS2_SUCCESS on success, else AXIS2_FAILURE
+*/
 AXIS2_EXTERN axis2_char_t *AXIS2_CALL
 rampart_rd_record_get_timestamp(
     const rampart_rd_record_t *rd_record,
     const axutil_env_t *env);
 
+/**
+* Set the ID
+* @param rd_record the record
+* @param env pointer to environment struct
+* @param id Record ID
+* @return AXIS2_SUCCESS on success, else AXIS2_FAILURE
+*/
 AXIS2_EXTERN axis2_status_t AXIS2_CALL
 rampart_rd_record_set_id(
     rampart_rd_record_t *rd_record,
     const axutil_env_t *env,
     axis2_char_t *id);
 
+/**
+* Set the timestamp
+* @param rd_record the record
+* @param env pointer to environment struct
+* @param timestamp the time stamp
+* @return AXIS2_SUCCESS on success, else AXIS2_FAILURE
+*/
 AXIS2_EXTERN axis2_status_t AXIS2_CALL
 rampart_rd_record_set_timestamp(
     rampart_rd_record_t *rd_record,
     const axutil_env_t *env,
     axis2_char_t *timestamp);
 
-AXIS2_EXTERN rampart_rd_record_t *AXIS2_CALL
-rampart_rd_record_create(const axutil_env_t *env);
-
-AXIS2_EXTERN axis2_status_t AXIS2_CALL
-rampart_rd_record_free(rampart_rd_record_t *rd_record,
-                  const axutil_env_t *env);
 
 
 

Modified: webservices/rampart/trunk/c/include/rampart_sec_header_builder.h
URL: http://svn.apache.org/viewvc/webservices/rampart/trunk/c/include/rampart_sec_header_builder.h?rev=576797&r1=576796&r2=576797&view=diff
==============================================================================
--- webservices/rampart/trunk/c/include/rampart_sec_header_builder.h (original)
+++ webservices/rampart/trunk/c/include/rampart_sec_header_builder.h Tue Sep 18 02:25:42 2007
@@ -24,7 +24,7 @@
 #include <oxs_xml_encryption.h>
 /**
   * @file rampart_sec_header_builder.h
-  * @brief 
+  * @brief Build the Security related SOAP headers
   */
 #ifndef RAMPART_SEC_HEADER_BUILDER_H
 #define RAMPART_SEC_HEADER_BUILDER_H

Modified: webservices/rampart/trunk/c/include/rampart_timestamp_token.h
URL: http://svn.apache.org/viewvc/webservices/rampart/trunk/c/include/rampart_timestamp_token.h?rev=576797&r1=576796&r2=576797&view=diff
==============================================================================
--- webservices/rampart/trunk/c/include/rampart_timestamp_token.h (original)
+++ webservices/rampart/trunk/c/include/rampart_timestamp_token.h Tue Sep 18 02:25:42 2007
@@ -61,7 +61,7 @@
         axis2_msg_ctx_t *msg_ctx,
         axiom_node_t *ts_node );
 
-
+ /* @} */
 #ifdef __cplusplus
 }
 #endif

Modified: webservices/rampart/trunk/c/samples/secpolicy/scenario5/services.xml
URL: http://svn.apache.org/viewvc/webservices/rampart/trunk/c/samples/secpolicy/scenario5/services.xml?rev=576797&r1=576796&r2=576797&view=diff
==============================================================================
--- webservices/rampart/trunk/c/samples/secpolicy/scenario5/services.xml (original)
+++ webservices/rampart/trunk/c/samples/secpolicy/scenario5/services.xml Tue Sep 18 02:25:42 2007
@@ -71,10 +71,11 @@
                     <rampc:EncryptionUser>b</rampc:EncryptionUser>
                     <rampc:PasswordType>Digest</rampc:PasswordType>
                     <rampc:PasswordCallbackClass>AXIS2C_HOME/bin/samples/rampart/callback/libpwcb.so</rampc:PasswordCallbackClass>
-                    <!--rampc:AuthnModuleName>/home/kau/axis2/c/deploy/bin/samples/rampart/authn_provider/libauthn.so</rampc:AuthnModuleName-->
+                    <!--rampc:AuthnModuleName>/AXIS2C_HOME/bin/samples/rampart/authn_provider/libauthn.so</rampc:AuthnModuleName-->
                     <rampc:ReceiverCertificate>AXIS2C_HOME/bin/samples/rampart/keys/bhome/alice_cert.cert</rampc:ReceiverCertificate>
                     <rampc:Certificate>AXIS2C_HOME/bin/samples/rampart/keys/bhome/bob_cert.cert</rampc:Certificate>
                     <rampc:PrivateKey>AXIS2C_HOME/bin/samples/rampart/keys/bhome/bob_key.pem</rampc:PrivateKey>
+                    <rampc:ReplayDetection>3</rampc:ReplayDetection>
                 </rampc:RampartConfig>
             </wsp:All>
         </wsp:ExactlyOne>