An authentication method applied to an electronic device, comprising:
- receiving target voice data;
- obtaining a first voiceprint feature parameter corresponding to the target voice data from a device voiceprint model library, wherein the device voiceprint model library is configured to store voiceprint feature parameters of authorized users in a local system of the electronic device, and the first voiceprint feature parameter is obtained by matching the voiceprint feature parameters corresponding to the target voice data with the voiceprint feature parameters of the authorized users in the device voiceprint model library;
- performing a first encryption process on the first voiceprint feature parameter with a locally stored private key to generate to-be-verified data;
- transmitting the to-be-verified data to a server, so that the server uses a public key which matches the private key to decrypt the to-be-verified data to obtain the first voiceprint feature parameter, and performs authentication on the first voiceprint feature parameter to obtain an authentication result;
- receiving the authentication result returned by the server, generating a corresponding data request according to a control instruction input by a user when the authentication result is successful authentication, and transmitting an encrypted data request to the server to enable the server to determine whether to execute a corresponding control instruction according to the data request and operable authority of a target user;
- wherein the performing a first encryption process on the first voiceprint feature parameter with a locally stored private key to generate to-be-verified data, comprises:
- obtaining a first hash value corresponding to the first voiceprint feature parameter via calculation;
- obtaining a device identifier of the electronic device;
- obtaining a group identifier of a group in which the first voiceprint feature parameter is located in the device voiceprint model library;
- encrypting the first hash value, the device identifier and the group identifier with the private key to generate the to-be-verified data;
- and
- wherein the obtaining a first voiceprint feature parameter corresponding to the target voice data from a device voiceprint model library, includes:
- extracting the target voiceprint feature parameter in the target voice data;
- matching the target voiceprint feature parameter with a plurality of voiceprint feature parameters pre-stored in the device voiceprint model library, thereby obtaining at least one matched voiceprint feature parameter;
- obtaining a matching probability value between the target voiceprint feature parameter and each of the at least one matched voiceprint feature parameter;
- determining the first voiceprint feature parameter from the at least one matched voiceprint feature parameter, according to a similarity criterion and the matching probability value.