Skip to content
Snippets Groups Projects
Commit c4d93f6e authored by YannGarcia's avatar YannGarcia
Browse files

Add UpperTester support

parent 0a28ff34
No related branches found
No related tags found
1 merge request!2Closing TTF T024/025
......@@ -129,7 +129,7 @@ OCTETSTRING LibSecurity__Hash::fx__hash(const OCTETSTRING& p_to_be_hashed, const
return hash;
}
OCTETSTRING LibSecurity__Signature::fx__enc__xmldsig__signed__info(const http__www__w3__org__2000__09__xmldsig::Signature_signedInfo& s) { // FIXME Use enc/dec TITAN function external function f_enc_value(in Value x) return bitstring with { extension "prototype(convert) encode(abc)" }
BITSTRING LibSecurity__Signature::fx__enc__xmldsig__signed__info(const http__www__w3__org__2000__09__xmldsig::Signature_signedInfo& s) { // FIXME Use enc/dec TITAN function external function f_enc_value(in Value x) return bitstring with { extension "prototype(convert) encode(abc)" }
loggers::get_instance().log(">>> fx__enc__xmldsig__signed__info");
TTCN_EncDec::clear_error();
......@@ -147,10 +147,10 @@ OCTETSTRING LibSecurity__Signature::fx__enc__xmldsig__signed__info(const http__w
OCTETSTRING os = char2oct(CHARSTRING(str.c_str()));
loggers::get_instance().log_msg("fx__enc__xmldsig__signed__info: os: ", os);
return os;
return oct2bit(os);
}
OCTETSTRING LibSecurity__Signature::fx__enc__xmldsig(const http__www__w3__org__2000__09__xmldsig::Signature& s) { // FIXME Use enc/dec TITAN function external function f_enc_value(in Value x) return bitstring with { extension "prototype(convert) encode(abc)" }
BITSTRING LibSecurity__Signature::fx__enc__xmldsig(const http__www__w3__org__2000__09__xmldsig::Signature& s) { // FIXME Use enc/dec TITAN function external function f_enc_value(in Value x) return bitstring with { extension "prototype(convert) encode(abc)" }
loggers::get_instance().log(">>> fx__enc__xmldsig");
TTCN_EncDec::clear_error();
......@@ -168,10 +168,10 @@ OCTETSTRING LibSecurity__Signature::fx__enc__xmldsig(const http__www__w3__org__2
OCTETSTRING os = char2oct(CHARSTRING(str.c_str()));
loggers::get_instance().log_msg("fx__enc__xmldsig: os: ", os);
return os;
return oct2bit(os);
}
INTEGER LibSecurity__Signature::fx__dec__xmldsig(const BITSTRING& bs, http__www__w3__org__2000__09__xmldsig::Signature& s) { // FIXME Use enc/dec TITAN function external function f_enc_value(in Value x) return bitstring with { extension "prototype(convert) encode(abc)" }
INTEGER LibSecurity__Signature::fx__dec__xmldsig(BITSTRING& bs, http__www__w3__org__2000__09__xmldsig::Signature& s) { // FIXME Use enc/dec TITAN function external function f_enc_value(in Value x) return bitstring with { extension "prototype(convert) encode(abc)" }
loggers::get_instance().log(">>> fx__dec__xmldsig");
std::string str(static_cast<const char*>(oct2char(bit2oct(bs))));
......
......@@ -22,19 +22,18 @@ module LibHttp_TestSystem {
inout HttpMessage;
}
type component HttpComponent extends SelfSyncComp { // FIXME To be rename into HttpTest
type component HttpComponent extends SelfSyncComp {
port HttpPort httpPort;
port HttpPort httpPort_notif;
// timers
timer tc_wait := PX_TWAIT;
timer tc_ac := PX_TAC;
timer tc_noac := PX_TNOAC;
} // End of component HttpComponent
type component HttpTestAdapter { // FIXME To be rename into HttpTestSystem
type component HttpTestAdapter {
port HttpPort httpPort;
port HttpPort httpPort_notif;
} // End of component TestAdapter
} // End of component HttpTestAdapter
} // End of module LibHttp_TestSystem
......@@ -2,15 +2,14 @@ module LibSecurity_Signature {
import from http_www_w3_org_2000_09_xmldsig all;
external function fx_enc_xmldsig_signed_info(in Signature.signedInfo s) return octetstring; // Use encvalue decoration
//external function fx_enc_PullRequest_1(in PullRequest p_pull_request) return bitstring with {extension "prototype(convert) encode(XML)"}
//external function fx_dec_PullRequest_1(inout bitstring b, out PullRequest p_pull_request)return integer with {extension "prototype(sliding) decode(XML)"}
external function fx_enc_xmldsig_signed_info(in Signature.signedInfo s) return bitstring
with {extension "prototype(convert) encode(XML)"};
external function fx_enc_xmldsig(in Signature s) return octetstring; // Use encvalue decoration
//external function fx_enc_PullRequest_1(in PullRequest p_pull_request) return bitstring with {extension "prototype(convert) encode(XML)"}
//external function fx_dec_PullRequest_1(inout bitstring b, out PullRequest p_pull_request)return integer with {extension "prototype(sliding) decode(XML)"}
external function fx_enc_xmldsig(in Signature s) return bitstring
with {extension "prototype(convert) encode(XML)"};
external function fx_dec_xmldsig(in bitstring bs, out Signature s) return integer;
external function fx_dec_xmldsig(inout bitstring bs, out Signature s) return integer
with {extension "prototype(sliding) decode(XML)"};
/**
* @desc Sign message
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment