Commit cdcc7f0f authored by Yann Garcia's avatar Yann Garcia
Browse files

Validating ERRATA changes

parent 4f503327
Loading
Loading
Loading
Loading
+34 −12
Original line number Original line Diff line number Diff line
@@ -65,9 +65,11 @@ module LibItsHttp_Functions {
        p_headers[v_i] := { c_header_pragma, { "no-cache" } };
        p_headers[v_i] := { c_header_pragma, { "no-cache" } };
        v_i := v_i + 1;
        v_i := v_i + 1;
        p_headers[v_i] := { c_header_cache_control, { "no-cache" } };
        p_headers[v_i] := { c_header_cache_control, { "no-cache" } };
        //v_i := v_i + 1;
        //p_headers[v_i] := { c_header_accept, { "application/x-its-response" } };
      } // End of function f_init_default_headers_list
      } // End of function f_init_default_headers_list
      
      
      function f_set_headears_list(
      function f_set_headers_list(
                                  in charstring_list p_headers_to_set,
                                  in charstring_list p_headers_to_set,
                                  in charstring_list p_headers_value,
                                  in charstring_list p_headers_value,
                                  inout HeaderLines p_headers
                                  inout HeaderLines p_headers
@@ -91,9 +93,9 @@ module LibItsHttp_Functions {
            }
            }
          } // End of 'for' statement 
          } // End of 'for' statement 
        } // End of 'for' statement
        } // End of 'for' statement
      } // End of function f_set_headears_list
      } // End of function f_set_headers_list
      
      
      function f_remove_headears_list(
      function f_remove_headers_list(
                                     in charstring_list p_headers_to_remove,
                                     in charstring_list p_headers_to_remove,
                                     inout HeaderLines p_headers
                                     inout HeaderLines p_headers
                                     ) {
                                     ) {
@@ -112,7 +114,27 @@ module LibItsHttp_Functions {
            }
            }
          } // End of 'for' statement
          } // End of 'for' statement
        } // End of 'for' statement
        } // End of 'for' statement
      } // End of function f_remove_headears_list
      } // End of function f_remove_headers_list
      
      function f_get_header(
                            in HeaderLines p_headers,
                            in charstring p_header_name := c_header_content_text,
                            out charstring_list p_header_value
                                      ) {
        // Sanity checks
        if (lengthof(p_header_name) == 0) {
          return;
        } else if (lengthof(p_headers) == 0) {
          return;
        }
        
        for (var integer v_jdx := 0; v_jdx < lengthof(p_headers); v_jdx := v_jdx + 1) {
          if (p_headers[v_jdx].header_name == p_header_name) {
            p_header_value := p_headers[v_jdx].header_value; // NOTE Codec won't encode it
            break;
          }
        } // End of 'for' statement
      } // End of function f_get_header
      
      
    } // End of group http_headers
    } // End of group http_headers
    
    
+331 −121

File changed.

Preview size limit exceeded, changes collapsed.

+35 −5
Original line number Original line Diff line number Diff line
@@ -15,11 +15,6 @@ module LibItsPki_Pics {
   */
   */
  modulepar boolean PICS_IUT_AA_ROLE := true;
  modulepar boolean PICS_IUT_AA_ROLE := true;
  
  
  /**
   * @desc Does the IUT act as combined EA-AA device?
   */
  modulepar boolean PICS_IUT_COMBINED_EA_AA_ROLE := false;

  /**
  /**
   * @desc Does the IUT support enrolment?
   * @desc Does the IUT support enrolment?
   */
   */
@@ -70,6 +65,26 @@ module LibItsPki_Pics {
   */
   */
  modulepar charstring PICS_TS_AA_CERTIFICATE_ID := "CERT_AA";
  modulepar charstring PICS_TS_AA_CERTIFICATE_ID := "CERT_AA";
  
  
  /**
   * @desc Set to true if different end points are used for EC and AT
   */
  modulepar boolean PICS_MULTIPLE_END_POINT := false;

  /**
   * @desc End point for the enrolment
   */
  modulepar charstring PICS_HEADER_HOST_EC := "www.its.ec.org";
  
  /**
   * @desc End point for the authorization validation
   */
  modulepar charstring PICS_HEADER_HOST_ATV := "www.its.atv.org";
  
  /**
   * @desc End point for the authorization
   */
  modulepar charstring PICS_HEADER_HOST_AT := "www.its.at.org";
  
  /**
  /**
   * @desc Certificate used by the Test System
   * @desc Certificate used by the Test System
   */
   */
@@ -80,6 +95,21 @@ module LibItsPki_Pics {
   */
   */
  modulepar boolean PICS_ITS_S_WITH_PRIVACY := true;
  modulepar boolean PICS_ITS_S_WITH_PRIVACY := true;
  
  
  /**
   * @desc HTTP POST URI for InnerECRequest
   */
  modulepar charstring PICS_HTTP_POST_URI_EC := "/enrolment";
  
  /**
   * @desc HTTP POST URI for InnerATRequest
   */
  modulepar charstring PICS_HTTP_POST_URI_AT := "/authorize";
  
  /**
   * @desc HTTP POST URI for authorization validation
   */
  modulepar charstring PICS_HTTP_POST_URI_ATV := "/authorize_validate";
  
  /**
  /**
   * @desc Factory private key for verification Nist P256
   * @desc Factory private key for verification Nist P256
   */
   */
+8 −0
Original line number Original line Diff line number Diff line
@@ -59,12 +59,20 @@ module LibItsPki_TestSystem {
     * @desc System component
     * @desc System component
     */
     */
    type component ItsPkiHttpSystem extends HttpTestAdapter{
    type component ItsPkiHttpSystem extends HttpTestAdapter{
                                              /** Use httPort when EC and AT are served by the same end point */
      port HttpPort httpEcPort;               /** Enrolment end point */
      port HttpPort httpAtVPort;              /** Authorization Validation end point */
      port HttpPort httpAtPort;               /** Authorization end point */ 
    } // End of component ItsPkiHttpSystem
    } // End of component ItsPkiHttpSystem
    
    
    /**
    /**
     * @desc Test component for PKI entities execpt ITS-S
     * @desc Test component for PKI entities execpt ITS-S
     */
     */
    type component ItsPkiHttp extends ItsSecurityBaseComponent, HttpComponent {
    type component ItsPkiHttp extends ItsSecurityBaseComponent, HttpComponent {
                                              /** Use httPort when EC and AT are served by the same end point */
      port HttpPort httpEcPort;               /** Enrolment end point */
      port HttpPort httpAtVPort;              /** Authorization Validation end point */
      port HttpPort httpAtPort;               /** Authorization end point */ 
      var Certificate vc_eaCertificate;       /** Test Adapter EA certificate */
      var Certificate vc_eaCertificate;       /** Test Adapter EA certificate */
      var octetstring vc_eaPrivateKey;        /** Test Adapter EA private key for signature */
      var octetstring vc_eaPrivateKey;        /** Test Adapter EA private key for signature */
      //      var Certificate vc_ecCertificate;       /** Test Adapter AA certificate */
      //      var Certificate vc_ecCertificate;       /** Test Adapter AA certificate */