Author: manjula
Date: Wed Jul 25 20:14:30 2007
New Revision: 559679

URL: http://svn.apache.org/viewvc?view=rev&rev=559679
Log:
due changes due to Changing rp_property type to a enum.

Modified:
    webservices/rampart/trunk/c/include/rampart_context.h
    webservices/rampart/trunk/c/src/handlers/rampart_in_handler.c
    webservices/rampart/trunk/c/src/util/rampart_context.c
    webservices/rampart/trunk/c/src/util/rampart_encryption.c
    webservices/rampart/trunk/c/src/util/rampart_sec_header_builder.c
    webservices/rampart/trunk/c/src/util/rampart_sec_header_processor.c
    webservices/rampart/trunk/c/src/util/rampart_signature.c

Modified: webservices/rampart/trunk/c/include/rampart_context.h
URL: 
http://svn.apache.org/viewvc/webservices/rampart/trunk/c/include/rampart_context.h?view=diff&rev=559679&r1=559678&r2=559679
==============================================================================
--- webservices/rampart/trunk/c/include/rampart_context.h (original)
+++ webservices/rampart/trunk/c/include/rampart_context.h Wed Jul 25 20:14:30 
2007
@@ -348,7 +348,7 @@
         rampart_context_t *rampart_context,
         const axutil_env_t *env);
 
-    AXIS2_EXTERN int AXIS2_CALL
+    AXIS2_EXTERN rp_property_type_t AXIS2_CALL
     rampart_context_get_binding_type(
         rampart_context_t *rampart_context,
         const axutil_env_t *env);
@@ -453,7 +453,7 @@
     rampart_context_is_token_include(
         rampart_context_t *rampart_context,
         rp_property_t *token,
-        int token_type,
+        rp_property_type_t token_type,
         axis2_bool_t server_side,
         axis2_bool_t is_inpath,
         const axutil_env_t *env);
@@ -473,7 +473,7 @@
 
     AXIS2_EXTERN axis2_bool_t AXIS2_CALL
     rampart_context_is_token_type_supported(
-        int token_type,
+        rp_property_type_t token_type,
         const axutil_env_t *env);
 
     AXIS2_EXTERN axis2_bool_t AXIS2_CALL

Modified: webservices/rampart/trunk/c/src/handlers/rampart_in_handler.c
URL: 
http://svn.apache.org/viewvc/webservices/rampart/trunk/c/src/handlers/rampart_in_handler.c?view=diff&rev=559679&r1=559678&r2=559679
==============================================================================
--- webservices/rampart/trunk/c/src/handlers/rampart_in_handler.c (original)
+++ webservices/rampart/trunk/c/src/handlers/rampart_in_handler.c Wed Jul 25 
20:14:30 2007
@@ -119,7 +119,7 @@
     
     sec_node = rampart_get_security_token(env, msg_ctx, soap_header);
 
-    if((rampart_context_get_binding_type(rampart_context,env)) != 
RP_BINDING_TRANSPORT)
+    if((rampart_context_get_binding_type(rampart_context,env)) != 
RP_PROPERTY_TRANSPORT_BINDING)
     {
         /*sec_node = rampart_get_security_token(env, msg_ctx, soap_header);*/
     
@@ -138,16 +138,7 @@
         AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, 
                                "[rampart][rampart_in_handler] Unable to set 
the security processed results");
     }
-    /*rampart_context = rampart_neethi_build_configuration(env, msg_ctx, 
AXIS2_TRUE);*/
 
-/*  rampart_context = rampart_engine_init(env,msg_ctx,AXIS2_TRUE);*/
-/*
-    if(!rampart_context)
-    {        
-        AXIS2_LOG_INFO(env->log, "[rampart][rampart_in_handler] 
ramaprt_context creation failed.");
-        return AXIS2_FAILURE;
-    }
-*/
     status = rampart_shp_process_message(env, msg_ctx, rampart_context, 
                                                soap_envelope, sec_node);
     

Modified: webservices/rampart/trunk/c/src/util/rampart_context.c
URL: 
http://svn.apache.org/viewvc/webservices/rampart/trunk/c/src/util/rampart_context.c?view=diff&rev=559679&r1=559678&r2=559679
==============================================================================
--- webservices/rampart/trunk/c/src/util/rampart_context.c (original)
+++ webservices/rampart/trunk/c/src/util/rampart_context.c Wed Jul 25 20:14:30 
2007
@@ -771,7 +771,7 @@
     return rampart_context->require_ut;
 }
 
-AXIS2_EXTERN int AXIS2_CALL
+AXIS2_EXTERN rp_property_type_t AXIS2_CALL
 rampart_context_get_binding_type(
     rampart_context_t *rampart_context,
     const axutil_env_t *env)
@@ -797,7 +797,7 @@
     if(!property)
         return NULL;
 
-    if(rp_property_get_type(property,env)==RP_BINDING_ASYMMETRIC)
+    if(rp_property_get_type(property,env) == RP_PROPERTY_ASYMMETRIC_BINDING)
     {
         rp_asymmetric_binding_t *asymmetric_binding = NULL;
         asymmetric_binding = 
(rp_asymmetric_binding_t*)rp_property_get_value(property,env);
@@ -806,7 +806,7 @@
 
         return 
rp_asymmetric_binding_get_symmetric_asymmetric_binding_commons(asymmetric_binding,env);
     }
-    else if(rp_property_get_type(property,env)==RP_BINDING_SYMMETRIC)
+    else if(rp_property_get_type(property,env) == 
RP_PROPERTY_SYMMETRIC_BINDING)
     {
         rp_symmetric_binding_t *symmetric_binding = NULL;
         symmetric_binding = 
(rp_symmetric_binding_t*)rp_property_get_value(property,env);
@@ -829,11 +829,11 @@
     if(!property)
         return NULL;
 
-    if(rp_property_get_type(property,env)==RP_BINDING_ASYMMETRIC)
+    if(rp_property_get_type(property,env) == RP_PROPERTY_ASYMMETRIC_BINDING)
     {
         rp_asymmetric_binding_t *asymmetric_binding = NULL;
         rp_symmetric_asymmetric_binding_commons_t *sym_asym_commons = NULL;
-        asymmetric_binding = 
(rp_asymmetric_binding_t*)rp_property_get_value(property,env);
+        asymmetric_binding = 
(rp_asymmetric_binding_t*)rp_property_get_value(property, env);
         if(!asymmetric_binding)
             return NULL;
 
@@ -843,7 +843,7 @@
 
         return 
rp_symmetric_asymmetric_binding_commons_get_binding_commons(sym_asym_commons,env);
     }
-    else if(rp_property_get_type(property,env)==RP_BINDING_SYMMETRIC)
+    else if(rp_property_get_type(property,env) == 
RP_PROPERTY_SYMMETRIC_BINDING)
     {
         rp_symmetric_binding_t *symmetric_binding = NULL;
         rp_symmetric_asymmetric_binding_commons_t *sym_asym_commons = NULL;
@@ -858,7 +858,7 @@
         return 
rp_symmetric_asymmetric_binding_commons_get_binding_commons(sym_asym_commons,env);
 
     }
-    else if(rp_property_get_type(property,env)==RP_BINDING_TRANSPORT)
+    else if(rp_property_get_type(property,env) == 
RP_PROPERTY_TRANSPORT_BINDING)
     {
         rp_transport_binding_t *transport_binding = NULL;
         transport_binding = 
(rp_transport_binding_t*)rp_property_get_value(property,env);
@@ -929,7 +929,7 @@
                     axutil_array_list_get(array_list,env, i);
             if (token)
             {
-                if(rp_property_get_type(token,env)==RP_TOKEN_USERNAME)
+                if(rp_property_get_type(token,env) == 
RP_PROPERTY_USERNAME_TOKEN)
                 {
                     rp_username_token_t *username_token =
                         (rp_username_token_t 
*)rp_property_get_value(token,env);
@@ -1153,7 +1153,7 @@
         return identifier;
     }
 
-    if(rp_property_get_type(wss,env)==RP_WSS_WSS10)
+    if(rp_property_get_type(wss,env) == RP_PROPERTY_WSS10)
     {
         rp_wss10_t *wss10 = NULL;
         wss10 = rp_property_get_value(wss,env);
@@ -1173,7 +1173,7 @@
 
         return identifier;
     }
-    else if(rp_property_get_type(wss,env)==RP_WSS_WSS11)
+    else if(rp_property_get_type(wss,env) == RP_PROPERTY_WSS11)
     {
         rp_wss11_t *wss11 = NULL;
         wss11 = rp_property_get_value(wss,env);
@@ -1218,16 +1218,16 @@
         return AXIS2_FALSE;
     }
 
-    if(rp_property_get_type(wss,env)==RP_WSS_WSS10)
+    if(rp_property_get_type(wss,env) == RP_PROPERTY_WSS10)
     {
-        wss10 = rp_property_get_value(wss,env);
+        wss10 = (rp_wss10_t *)rp_property_get_value(wss,env);
     }
-    else if(rp_property_get_type(wss,env)==RP_WSS_WSS11)
+    else if(rp_property_get_type(wss,env) == RP_PROPERTY_WSS11)
     {
-        wss11 = rp_property_get_value(wss,env);
+        wss11 = (rp_wss11_t *)rp_property_get_value(wss,env);
     }
 
-    if(rp_property_get_type(token,env)==RP_TOKEN_X509)
+    if(rp_property_get_type(token,env)== RP_PROPERTY_X509_TOKEN)
     {
         rp_x509_token_t *x509_token = NULL;
         x509_token = (rp_x509_token_t *)rp_property_get_value(token,env);
@@ -1270,16 +1270,16 @@
         return AXIS2_FALSE;
     }
 
-    if(rp_property_get_type(wss,env)==RP_WSS_WSS10)
+    if(rp_property_get_type(wss,env)== RP_PROPERTY_WSS10)
     {
-        wss10 = rp_property_get_value(wss,env);
+        wss10 = (rp_wss10_t *)rp_property_get_value(wss,env);
     }
-    else if(rp_property_get_type(wss,env)==RP_WSS_WSS11)
+    else if(rp_property_get_type(wss,env)== RP_PROPERTY_WSS11)
     {
-        wss11 = rp_property_get_value(wss,env);
+        wss11 = (rp_wss11_t *)rp_property_get_value(wss,env);
     }
 
-    if(rp_property_get_type(token,env)==RP_TOKEN_X509)
+    if(rp_property_get_type(token,env) == RP_PROPERTY_X509_TOKEN)
     {
         rp_x509_token_t *x509_token = NULL;
         x509_token = (rp_x509_token_t *)rp_property_get_value(token,env);
@@ -1322,16 +1322,16 @@
         return AXIS2_FALSE;
     }
 
-    if(rp_property_get_type(wss,env)==RP_WSS_WSS10)
+    if(rp_property_get_type(wss,env) == RP_PROPERTY_WSS10)
     {
-        wss10 = rp_property_get_value(wss,env);
+        wss10 = (rp_wss10_t *)rp_property_get_value(wss,env);
     }
-    else if(rp_property_get_type(wss,env)==RP_WSS_WSS11)
+    else if(rp_property_get_type(wss,env) == RP_PROPERTY_WSS11)
     {
-        wss11 = rp_property_get_value(wss,env);
+        wss11 = (rp_wss11_t *)rp_property_get_value(wss,env);
     }
 
-    if(rp_property_get_type(token,env)==RP_TOKEN_X509)
+    if(rp_property_get_type(token,env) == RP_PROPERTY_X509_TOKEN)
     {
         rp_x509_token_t *x509_token = NULL;
         x509_token = (rp_x509_token_t *)rp_property_get_value(token,env);
@@ -1824,7 +1824,7 @@
     if(!binding)
         return NULL;
 
-    if(rp_property_get_type(binding,env)==RP_BINDING_ASYMMETRIC)
+    if(rp_property_get_type(binding,env) == RP_PROPERTY_ASYMMETRIC_BINDING)
     {
         rp_asymmetric_binding_t *asym_binding = NULL;
         asym_binding = (rp_asymmetric_binding_t 
*)rp_property_get_value(binding,env);
@@ -1859,7 +1859,7 @@
             return NULL;
     }
     /*In symmetric binding same tokens are used in the client and server 
sides.*/
-    else if(rp_property_get_type(binding,env)==RP_BINDING_SYMMETRIC)
+    else if(rp_property_get_type(binding,env) == RP_PROPERTY_SYMMETRIC_BINDING)
     {
         rp_symmetric_binding_t *sym_binding = NULL;
         rp_property_t *token = NULL;
@@ -1886,7 +1886,7 @@
         else
             return NULL;
     }
-    else if(rp_property_get_type(binding,env)==RP_BINDING_TRANSPORT)
+    else if(rp_property_get_type(binding,env) == RP_PROPERTY_TRANSPORT_BINDING)
     {
         rp_transport_binding_t *transport_binding = NULL;
         transport_binding = (rp_transport_binding_t 
*)rp_property_get_value(binding,env);
@@ -1904,7 +1904,7 @@
     const axutil_env_t *env,
     rp_property_t *token)
 {
-    if(rp_property_get_type(token,env)==RP_TOKEN_X509)
+    if(rp_property_get_type(token,env) == RP_PROPERTY_X509_TOKEN)
     {
         rp_x509_token_t *x509_token = NULL;
         x509_token = (rp_x509_token_t *)rp_property_get_value(token,env);
@@ -2060,10 +2060,10 @@
 
 AXIS2_EXTERN axis2_bool_t AXIS2_CALL
 rampart_context_is_token_type_supported(
-    int token_type,
+    rp_property_type_t token_type,
     const axutil_env_t *env)
 {
-    if(token_type == RP_TOKEN_X509)
+    if(token_type == RP_PROPERTY_X509_TOKEN)
         return AXIS2_TRUE;
     else
     {
@@ -2078,7 +2078,7 @@
 rampart_context_is_token_include(
     rampart_context_t *rampart_context,
     rp_property_t *token,
-    int token_type,
+    rp_property_type_t token_type,
     axis2_bool_t server_side,
     axis2_bool_t is_inpath,
     const axutil_env_t *env)
@@ -2086,7 +2086,7 @@
     axis2_char_t *inclusion = NULL;
     axis2_bool_t include = AXIS2_FALSE;
 
-    if(token_type == RP_TOKEN_X509)
+    if(token_type == RP_PROPERTY_X509_TOKEN)
     {
         rp_x509_token_t *x509_token = NULL;
         x509_token = (rp_x509_token_t *)rp_property_get_value(token,env);
@@ -2132,7 +2132,7 @@
 {
     axis2_char_t *identifier = NULL;
 
-    if(rp_property_get_type(token,env)==RP_TOKEN_X509)
+    if(rp_property_get_type(token,env) == RP_PROPERTY_X509_TOKEN)
     {
         rp_x509_token_t *x509_token = NULL;
         x509_token = (rp_x509_token_t *)rp_property_get_value(token,env);

Modified: webservices/rampart/trunk/c/src/util/rampart_encryption.c
URL: 
http://svn.apache.org/viewvc/webservices/rampart/trunk/c/src/util/rampart_encryption.c?view=diff&rev=559679&r1=559678&r2=559679
==============================================================================
--- webservices/rampart/trunk/c/src/util/rampart_encryption.c (original)
+++ webservices/rampart/trunk/c/src/util/rampart_encryption.c Wed Jul 25 
20:14:30 2007
@@ -77,7 +77,7 @@
     oxs_key_t *session_key = NULL;
     oxs_asym_ctx_t *asym_ctx = NULL;
     axis2_bool_t server_side = AXIS2_FALSE;
-    int token_type = 0;
+    rp_property_type_t token_type;
     rp_property_t *token = NULL;
     axis2_char_t *enc_user = NULL;
     rampart_callback_t *password_callback = NULL;

Modified: webservices/rampart/trunk/c/src/util/rampart_sec_header_builder.c
URL: 
http://svn.apache.org/viewvc/webservices/rampart/trunk/c/src/util/rampart_sec_header_builder.c?view=diff&rev=559679&r1=559678&r2=559679
==============================================================================
--- webservices/rampart/trunk/c/src/util/rampart_sec_header_builder.c (original)
+++ webservices/rampart/trunk/c/src/util/rampart_sec_header_builder.c Wed Jul 
25 20:14:30 2007
@@ -103,7 +103,7 @@
               axiom_node_get_data_element(sec_node, env);
 
     /*check the binding*/
-    if((rampart_context_get_binding_type(rampart_context,env)) == 
RP_BINDING_ASYMMETRIC)
+    if((rampart_context_get_binding_type(rampart_context,env)) == 
RP_PROPERTY_ASYMMETRIC_BINDING)
     {
         /*Do Asymmetric Binding specific things*/
 
@@ -271,13 +271,13 @@
 
         return AXIS2_SUCCESS;
     }
-    else if((rampart_context_get_binding_type(rampart_context,env)) == 
RP_BINDING_SYMMETRIC)
+    else if((rampart_context_get_binding_type(rampart_context,env)) == 
RP_PROPERTY_SYMMETRIC_BINDING)
     {
         /*Do Symmetric_binding specific things*/
         AXIS2_LOG_INFO(env->log, "[rampart][shb] Symmetric Binding. We do not 
support yet");
         return AXIS2_FAILURE;
     }
-    else if((rampart_context_get_binding_type(rampart_context,env)) == 
RP_BINDING_TRANSPORT)
+    else if((rampart_context_get_binding_type(rampart_context,env)) == 
RP_PROPERTY_TRANSPORT_BINDING)
     {
         /*Timestamp Inclusion*/
 

Modified: webservices/rampart/trunk/c/src/util/rampart_sec_header_processor.c
URL: 
http://svn.apache.org/viewvc/webservices/rampart/trunk/c/src/util/rampart_sec_header_processor.c?view=diff&rev=559679&r1=559678&r2=559679
==============================================================================
--- webservices/rampart/trunk/c/src/util/rampart_sec_header_processor.c 
(original)
+++ webservices/rampart/trunk/c/src/util/rampart_sec_header_processor.c Wed Jul 
25 20:14:30 2007
@@ -566,7 +566,7 @@
     rp_property_t *token = NULL;
     axis2_bool_t server_side = AXIS2_FALSE;
     axis2_char_t *eki = NULL;
-    int token_type = 0;
+    rp_property_type_t token_type;
     axiom_node_t *key_info_node = NULL;
     axiom_node_t *str_node = NULL;
     axiom_node_t *str_child_node = NULL;
@@ -857,7 +857,7 @@
 
     
 
-    if((rampart_context_get_binding_type(rampart_context,env)) == 
RP_BINDING_ASYMMETRIC)
+    if((rampart_context_get_binding_type(rampart_context,env)) == 
RP_PROPERTY_ASYMMETRIC_BINDING)
     {
 
         signature_protection = 
rampart_context_is_encrypt_signature(rampart_context, env);
@@ -1093,12 +1093,12 @@
         /*Do the action accordingly*/
         return AXIS2_SUCCESS;
     }
-    else if((rampart_context_get_binding_type(rampart_context,env)) == 
RP_BINDING_SYMMETRIC)
+    else if((rampart_context_get_binding_type(rampart_context,env)) == 
RP_PROPERTY_SYMMETRIC_BINDING)
     {
         AXIS2_LOG_INFO(env->log, "[rampart][shp] We still not support 
Symmetric binding.");
         return AXIS2_FAILURE;
     }
-    else if((rampart_context_get_binding_type(rampart_context,env)) == 
RP_BINDING_TRANSPORT)
+    else if((rampart_context_get_binding_type(rampart_context,env)) == 
RP_PROPERTY_TRANSPORT_BINDING)
     {
         axis2_status_t status = AXIS2_FAILURE;
 

Modified: webservices/rampart/trunk/c/src/util/rampart_signature.c
URL: 
http://svn.apache.org/viewvc/webservices/rampart/trunk/c/src/util/rampart_signature.c?view=diff&rev=559679&r1=559678&r2=559679
==============================================================================
--- webservices/rampart/trunk/c/src/util/rampart_signature.c (original)
+++ webservices/rampart/trunk/c/src/util/rampart_signature.c Wed Jul 25 
20:14:30 2007
@@ -130,7 +130,7 @@
     axis2_char_t *prv_key_file = NULL;
     axis2_char_t *password = NULL;
     axis2_bool_t server_side = AXIS2_FALSE;
-    int token_type = 0;
+    rp_property_type_t token_type;
     rp_property_t *token = NULL;
     axis2_char_t *enc_user = NULL;
     openssl_pkey_t *prvkey = NULL;


Reply via email to