0% found this document useful (0 votes)
6 views1 page

MSNCryptoAPI Linux

The MSNCrypto API provides functions for encrypting and decrypting the Machine Serial Number (MSN) using a shared library on Linux. Key functions include 'encrypt' for storing the encrypted MSN in a specified file, 'decrypt' for retrieving the MSN from the encrypted file, and password management functions to verify and change the password. The API requires the password to be verified before changing or encrypting the MSN.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
6 views1 page

MSNCryptoAPI Linux

The MSNCrypto API provides functions for encrypting and decrypting the Machine Serial Number (MSN) using a shared library on Linux. Key functions include 'encrypt' for storing the encrypted MSN in a specified file, 'decrypt' for retrieving the MSN from the encrypted file, and password management functions to verify and change the password. The API requires the password to be verified before changing or encrypting the MSN.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 1

MSNCrypto API(Linux)

Shared library - LIBMSNCRYPTOAPI.SO


Encrypted file - /etc/msn.inf
 bool encrypt(const char * file, unsigned char *in_buf);
 This is the method for the encryption of the Machine Serial Number(MSN).
 This function has two parameters : file – the path where the encrypted msn.inf will be
stored (/etc/msn.inf) & in_buf – A buffer which contains the MSN.
 This method encrypts the contents of in_buf buffer using the password and after
encryption, it writes the encrypted data to the file at the location mentioned in file
parameter.
 Returns ‘true’ if successful or ‘false’ in case of failure to encrypt the data.

 bool decrypt(const char *file, unsigned char *data);


 This is the method for the decryption of the MSN.
 The function signature is similar to encrypt API, but here the difference is we’ve to
pass in file – the msn encrypted file (/etc/msn.inf) & data - buffer in which the
decrypted data will be filled.
 Returns ‘true’ if successful or ‘false’ in case of failure to decrypt the data.
 NOTE: It’s necessary to call encrypt() at least once before calling decrypt().

NOTE : These functions are for MSNCrypto Tool .


 bool verifyPassword(const char *password);
 This function is used to verify the entered password.
 This function takes the password as argument.
 Returns ‘true’ if the entered password is correct or ‘false’ on incorrect password.

 bool changePassword(const char *new_password);


 This function is used to change the default/existing password.
 The argument to be passed is the new password entered by user.
 NOTE: It’s necessary to call verifyPassword() to verify the old password and only if it
returns true for the old password, accept the new password and call this function.
 Returns ‘true’ for success or ‘false’ for failure in setting the new password.
MSNCrypto tool :
o Button 1 :change password-- > To change password :verifyPassword()needs to be called first for
old password.--> if true call changePassword(const char *new_password)

o Button 2 : Set MSN : verify password if return true  bool encrypt(const char *
file, unsigned char *in_buf);

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy