66//! are the real implementors of the operations that Parsec claims to support. They map to
77//! functionality in the underlying hardware which allows the PSA Crypto operations to be
88//! backed by a hardware root of trust.
9+ use log:: trace;
910use parsec_interface:: requests:: { Opcode , ProviderID } ;
1011use serde:: Deserialize ;
1112use std:: collections:: HashSet ;
@@ -88,16 +89,19 @@ pub trait Provide {
8889 ///
8990 /// The descriptions are gathered in the Core Provider and returned for a ListProviders operation.
9091 fn describe ( & self ) -> Result < ( list_providers:: ProviderInfo , HashSet < Opcode > ) > {
92+ trace ! ( "describe ingress" ) ;
9193 Err ( ResponseStatus :: PsaErrorNotSupported )
9294 }
9395
9496 /// List the providers running in the service.
9597 fn list_providers ( & self , _op : list_providers:: Operation ) -> Result < list_providers:: Result > {
98+ trace ! ( "list_providers ingress" ) ;
9699 Err ( ResponseStatus :: PsaErrorNotSupported )
97100 }
98101
99102 /// List the opcodes supported by the given provider.
100103 fn list_opcodes ( & self , _op : list_opcodes:: Operation ) -> Result < list_opcodes:: Result > {
104+ trace ! ( "list_opcodes ingress" ) ;
101105 Err ( ResponseStatus :: PsaErrorNotSupported )
102106 }
103107
@@ -108,6 +112,7 @@ pub trait Provide {
108112 /// This operation will only fail if not implemented. It will never fail when being called on
109113 /// the `CoreProvider`.
110114 fn ping ( & self , _op : ping:: Operation ) -> Result < ping:: Result > {
115+ trace ! ( "ping ingress" ) ;
111116 Err ( ResponseStatus :: PsaErrorNotSupported )
112117 }
113118
@@ -117,6 +122,7 @@ pub trait Provide {
117122 _app_name : ApplicationName ,
118123 _op : psa_generate_key:: Operation ,
119124 ) -> Result < psa_generate_key:: Result > {
125+ trace ! ( "psa_generate_key ingress" ) ;
120126 Err ( ResponseStatus :: PsaErrorNotSupported )
121127 }
122128
@@ -126,6 +132,7 @@ pub trait Provide {
126132 _app_name : ApplicationName ,
127133 _op : psa_import_key:: Operation ,
128134 ) -> Result < psa_import_key:: Result > {
135+ trace ! ( "psa_import_key ingress" ) ;
129136 Err ( ResponseStatus :: PsaErrorNotSupported )
130137 }
131138
@@ -135,6 +142,7 @@ pub trait Provide {
135142 _app_name : ApplicationName ,
136143 _op : psa_export_public_key:: Operation ,
137144 ) -> Result < psa_export_public_key:: Result > {
145+ trace ! ( "psa_export_public_key ingress" ) ;
138146 Err ( ResponseStatus :: PsaErrorNotSupported )
139147 }
140148
@@ -144,6 +152,7 @@ pub trait Provide {
144152 _app_name : ApplicationName ,
145153 _op : psa_destroy_key:: Operation ,
146154 ) -> Result < psa_destroy_key:: Result > {
155+ trace ! ( "psa_destroy_key ingress" ) ;
147156 Err ( ResponseStatus :: PsaErrorNotSupported )
148157 }
149158
@@ -154,6 +163,7 @@ pub trait Provide {
154163 _app_name : ApplicationName ,
155164 _op : psa_sign_hash:: Operation ,
156165 ) -> Result < psa_sign_hash:: Result > {
166+ trace ! ( "psa_sign_hash ingress" ) ;
157167 Err ( ResponseStatus :: PsaErrorNotSupported )
158168 }
159169
@@ -163,6 +173,7 @@ pub trait Provide {
163173 _app_name : ApplicationName ,
164174 _op : psa_verify_hash:: Operation ,
165175 ) -> Result < psa_verify_hash:: Result > {
176+ trace ! ( "psa_verify_hash ingress" ) ;
166177 Err ( ResponseStatus :: PsaErrorNotSupported )
167178 }
168179}
0 commit comments