@@ -6,9 +6,9 @@ pub use constrained::*;
66use secrecy:: ExposeSecret as _;
77use secrecy:: SecretString ;
88use ssh_encoding:: { self , CheckedSum , Decode , Encode , Reader , Writer } ;
9- use ssh_key:: public:: KeyData ;
109
1110use super :: PrivateCredential ;
11+ use crate :: proto:: PublicCredential ;
1212use crate :: proto:: { Error , Result } ;
1313
1414/// Add a key to an agent.
@@ -101,25 +101,25 @@ impl PartialEq for SmartcardKey {
101101#[ derive( Clone , PartialEq , Debug ) ]
102102pub struct RemoveIdentity {
103103 /// The public key portion of the [`Identity`](super::Identity) to be removed
104- pub pubkey : KeyData ,
104+ pub credential : PublicCredential ,
105105}
106106
107107impl Decode for RemoveIdentity {
108108 type Error = Error ;
109109
110110 fn decode ( reader : & mut impl Reader ) -> Result < Self > {
111- let pubkey = reader. read_prefixed ( KeyData :: decode) ?;
111+ let credential = reader. read_prefixed ( PublicCredential :: decode) ?;
112112
113- Ok ( Self { pubkey } )
113+ Ok ( Self { credential } )
114114 }
115115}
116116
117117impl Encode for RemoveIdentity {
118118 fn encoded_len ( & self ) -> ssh_encoding:: Result < usize > {
119- self . pubkey . encoded_len_prefixed ( )
119+ self . credential . encoded_len_prefixed ( )
120120 }
121121
122122 fn encode ( & self , writer : & mut impl Writer ) -> ssh_encoding:: Result < ( ) > {
123- self . pubkey . encode_prefixed ( writer)
123+ self . credential . encode_prefixed ( writer)
124124 }
125125}
0 commit comments