1
0
mirror of https://github.com/bitwarden/browser synced 2026-02-08 12:40:26 +00:00

cleaned up some dead code

This commit is contained in:
Anders Åberg
2025-07-07 13:35:37 +02:00
parent b9ebd1a241
commit 9fa611cb50

View File

@@ -423,112 +423,3 @@ pub struct WEBAUTHN_CREDENTIAL_LIST {
pub cCredentials: u32,
pub ppCredentials: *const *const WEBAUTHN_CREDENTIAL_EX,
}
// Forward declarations for Windows types we need
type WEBAUTHN_ASSERTION = *const u8; // Placeholder - would need actual definition
type PCWEBAUTHN_USER_ENTITY_INFORMATION = *const u8; // Placeholder - would need actual definition
//type WEBAUTHN_CREDENTIAL_LIST = *const u8; // Placeholder - would need actual definition
type EXPERIMENTAL_PWEBAUTHN_CTAPCBOR_AUTHENTICATOR_OPTIONS = *const u8; // Placeholder
type EXPERIMENTAL_PWEBAUTHN_CTAPCBOR_HMAC_SALT_EXTENSION = *const u8; // Placeholder
/// CTAP CBOR Get Assertion Request structure
/// Header File Name: _EXPERIMENTAL_WEBAUTHN_CTAPCBOR_GET_ASSERTION_REQUEST
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct ExperimentalWebAuthnCtapCborGetAssertionRequest {
// Version of this structure, to allow for modifications in the future.
pub version: u32, // DWORD dwVersion
// RP ID. After UTF8 to Unicode conversion,
pub rpid_unicode: *const u16, // PCWSTR pwszRpId
// Input RP ID. Raw UTF8 bytes before conversion.
// These are the bytes to be hashed in the Authenticator Data.
pub rpid_byte_count: u32, // DWORD cbRpId
pub rpid_bytes: *const u8, // PBYTE pbRpId
// Client Data Hash
pub client_data_hash_byte_count: u32, // DWORD cbClientDataHash
pub client_data_hash: *const u8, // PBYTE pbClientDataHash
// Credentials used for inclusion
pub credential_list: WEBAUTHN_CREDENTIAL_LIST, // WEBAUTHN_CREDENTIAL_LIST CredentialList
// Optional extensions to parse when performing the operation.
pub cbor_extensions_map_byte_count: u32, // DWORD cbCborExtensionsMap
pub cbor_extensions_map: *const u8, // PBYTE pbCborExtensionsMap
// Authenticator Options (Optional)
pub authenticator_options: EXPERIMENTAL_PWEBAUTHN_CTAPCBOR_AUTHENTICATOR_OPTIONS,
// Pin Auth (Optional)
pub empty_pin_auth: i32, // BOOL fEmptyPinAuth
pub pin_auth_byte_count: u32, // DWORD cbPinAuth
pub pin_auth: *const u8, // PBYTE pbPinAuth
// HMAC Salt Extension (Optional)
pub hmac_salt_extension: EXPERIMENTAL_PWEBAUTHN_CTAPCBOR_HMAC_SALT_EXTENSION,
// PRF Extension
pub hmac_secret_salt_values_byte_count: u32, // DWORD cbHmacSecretSaltValues
pub hmac_secret_salt_values: *const u8, // PBYTE pbHmacSecretSaltValues
pub pin_protocol: u32, // DWORD dwPinProtocol
// "credBlob": true extension
pub cred_blob_ext: i32, // LONG lCredBlobExt
// "largeBlobKey": true extension
pub large_blob_key_ext: i32, // LONG lLargeBlobKeyExt
// "largeBlob" extension
pub cred_large_blob_operation: u32, // DWORD dwCredLargeBlobOperation
pub cred_large_blob_compressed_byte_count: u32, // DWORD cbCredLargeBlobCompressed
pub cred_large_blob_compressed: *const u8, // PBYTE pbCredLargeBlobCompressed
pub cred_large_blob_original_size: u32, // DWORD dwCredLargeBlobOriginalSize
// "json" extension. Nonzero if present
pub json_ext_byte_count: u32, // DWORD cbJsonExt
pub json_ext: *const u8, // PBYTE pbJsonExt
}
pub type ExperimentalPWebAuthnCtapCborGetAssertionRequest = *mut ExperimentalWebAuthnCtapCborGetAssertionRequest;
pub type ExperimentalPcWebAuthnCtapCborGetAssertionRequest = *const ExperimentalWebAuthnCtapCborGetAssertionRequest;
/// CTAP CBOR Get Assertion Response structure
/// Header File Name: _EXPERIMENTAL_WEBAUTHN_CTAPCBOR_GET_ASSERTION_RESPONSE
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct ExperimentalWebAuthnCtapCborGetAssertionResponse {
// [1] credential (optional)
// [2] authenticatorData
// [3] signature
pub webauthn_assertion: WEBAUTHN_ASSERTION,
// [4] user (optional)
pub user_information: PCWEBAUTHN_USER_ENTITY_INFORMATION,
// [5] numberOfCredentials (optional)
pub number_of_credentials: u32, // DWORD
// [6] userSelected (optional)
pub user_selected: i32, // LONG
// [7] largeBlobKey (optional)
pub large_blob_key_byte_count: u32, // DWORD
pub large_blob_key: *mut u8, // PBYTE
// [8] unsignedExtensionOutputs
pub unsigned_extension_outputs_byte_count: u32, // DWORD
pub unsigned_extension_outputs: *mut u8, // PBYTE
}
pub type ExperimentalPWebAuthnCtapCborGetAssertionResponse = *mut ExperimentalWebAuthnCtapCborGetAssertionResponse;
pub type ExperimentalPcWebAuthnCtapCborGetAssertionResponse = *const ExperimentalWebAuthnCtapCborGetAssertionResponse;
/// Function signature for encoding get assertion response
type EXPERIMENTAL_WebAuthNEncodeGetAssertionResponseFnDeclaration = unsafe extern "stdcall" fn(
pGetAssertionResponse: ExperimentalPcWebAuthnCtapCborGetAssertionResponse,
pcbResp: *mut u32,
ppbResp: *mut *mut u8,
) -> HRESULT;