Package: crid
RFID ClientThis is a command-line interface (CLI) application for interacting with Mifare Classic 1K cards using a NFC reader.InstallationLinux requires some libraries to be installed:sudoapt-getupdate
sudoapt-getinstalllibpcsclite-devlibpcsclite1pcscdpcsc-toolsInstallation through pip package managerpip3installcridInstallation from sourcegitclonehttps://github.com/VinnieV/crid.gitcdcrid
pip3install.If thecridcommand is not available after using any of these installation methods, please review the detailed installation walkthrough below.Executing from source:gitclonehttps://github.com/VinnieV/crid.gitcdcrid
pip3install-rrequirements.txt
python3main.pyUsage/Examples# Read the UID of the cardcrid--read_uid# Identify the card to the usercrid--identify# Read a block from the card using key type A and key value ffffffffffffcrid--read_block2--key_typeA--key_valueffffffffffff# Write "Hello, World!" to block 3 using key type B and key value a1b2c3d4e5f6crid--write_block3--data"48656C6C6F2C20576F726C6421"--key_typeB--key_valuea1b2c3d4e5f6# Read sector 1 from the card using key type A and key value ffffffffffffcrid--read_sector1--key_typeA--key_valueffffffffffff# Read all 16 sectors from the card using key type B and key value a1b2c3d4e5f6crid--read_full--key_typeB--key_valuea1b2c3d4e5f6# Find keys for a Mifare Classic card (requires mfoc binary)crid--find_mifare_keys# Brute force keys for block 18 using the key list file keys.txtcrid--brute_force_keys18--key_listmifare_access_keys_top100.lst# Mute the buzzer on the readercrid--mute# Provide the flag optioncrid--flag# Enable the buzzer on the readercrid--beep# Set the log level to DEBUGcrid--log_levelDEBUG# Send an APDU command to the NFC devicecrid--apdu_command00A4040007A000000003101000# Set the data format to stringcrid--data_formatstringAPI ReferenceThe main class in this project is RFIDClient within thecli.pysource file which provides methods to interact with the NFC reader and the Mifare Classic 1K card.Detailed Installation WalkthroughTo install the RFID Client application, follow the steps below:Clone the repository using the following command:gitclonehttps://github.com/VinnieV/crid.gitNavigate to the cloned repository:cdcridIf you have Python 3 installed, pip3 should be available. If not, you can install Python 3 and pip3 by following the instructions provided in the links below:Install Python 3Install pip3Install the application using pip3. There are two ways to install pip packages: as a user or system-wide. Choose the appropriate method based on your requirements:System-wide:pip3install.User-wide:pip3install.--userAdd the Python Scripts directory to your PATH environment variable. This step is necessary to ensure that thecridbinary is accessible from anywhere in the command prompt or terminal. The process for adding the Python path to the PATH variable differs between Windows and Linux:Windows:Open the Start menu and search for "Environment Variables".Click on "Edit the system environment variables".In the System Properties window, click on the "Environment Variables" button.In the "System Variables" section, select the "Path" variable and click on "Edit".Execute the following command to retrieve the path:pip3showcridBased on the Location listed there you can find the Python Scripts folder, the path should look something similar like this:c:\users\<username>\appdata\local\packages\pythonsoftwarefoundation.python.3.8_qbz5n2kfra8p0\localcache\local-packages\python38\ScriptsClick "OK" to save the changes.Linux:Open a terminal window.Edit the.bashrcor.bash_profilefile in your home directory using a text editor (e.g.,nano ~/.bashrc).Add the following line at the end of the file, replacing<username>with the your linux username:exportPATH="/home/<username>/.local/bin/:$PATH"Save the file and exit the text editor.Run the following command to apply the changes:source~/.bashrcOnce you have completed these steps, you should be able to use the RFID Client application successfully.Build for distributingpip3install--upgradebuild
python3-mbuild
pip3install--upgradetwine
python3-mtwineuploaddist/*