IC card Programming

Source: Internet
Author: User

1. About Devices

1. card reader is Shenzhen Minghua Aohan technology company RD-EB Card Reader

2. Introduction to SLE4442 Carter

1. The SLE4442 card is a 256-byte Encryption Card with Data Reading, writing, data protection, and password operations.

Electrical Performance

256x8-bit EEPROM
Byte direct addressing
32-byte data with a low address sets an unrecoverable write protection bit
32-bit Protection
End mark of data write operation
Reset response meeting 7816-3 Standard
Bytes erased and then written at: standard value 25 ms
Minimum write erasure cycle of 10000 times
Data Retention Period: 10 Years
Confidentiality

Three-byte user password.
Before the password is verified correctly, all data is readable and cannot be rewritten.
After checking that the password is correct, you can change the data, including the password. See password operation examples
Error counter. The initial value is 3. If the password verification fails once, the value is reduced by 1. If the counter value is 0, the card is locked automatically and the data can only be read, you cannot change the password or check the password. If the password is correct once, it can be restored to the initial value of 3.
Each byte of the write protection area (the first 32 bytes) can be individually protected. After the write protection, the content cannot be changed (that is, the solidified data ). See protection operation examples
 

Provides operation functions (see the example)

Write operation function: swr_4442 ()

Read operation function: srd_4442 ()

Card Test function: chk_4442 ()

Verification password function: csc_4442 ()

Password reading function: rsc_4442 ()

Change Password function: wsc_4442 ()

Read Password error count: rsct_4442 ()

Write protection bit function: pwr_4442 ()

Read protection bit function: prd_4442 ()
 

Ii. Storage zone allocation

See:
  

Iii. Function Description

1. Each byte of the write protection area (the first 32 bytes) can be individually protected.

Change (that is, curing data ).

2. All data can be read before the password is verified correctly. If necessary, you can properly encrypt the data.

3. Check that the password is correct and you can write or modify it.

4. The password of A Three-byte user can be changed after the password is verified correctly. The password is valid until it is powered off.

5. Password error counter. The initial value is 3. If the password verification fails once, the value is reduced by 1. If the counter value is 0, the system automatically

Locked, count

The data can only be read, no change can be made, and no password verification can be performed. If the value is not zero, the password verification is correct once.

, Can be restored to the initial value.

6. byte address 21 ~ 26. It is the user code. Our company can set up a unique global code for large users to use

Unified issuance and use by users (all cards cannot be modified after leaving the factory ).

7. byte address 0 ~ 5, 6 ~ 7 it has been written by the manufacturer before leaving the factory and cannot be changed.

8. Pay attention to the additional address in the password area, which is not 0 ~ Within 256 bytes.

Iv. Notes

1. SLE4442 has three security mechanisms: User Password, unique code, and fixed write. If the password is not checked correctly

Data cannot be written. Once written data is protected (solidified), it cannot be changed. Use unique code as the system

The ID of the IC card to prevent counterfeit cards of the same model from entering the system.

2. SLE4442 card can read the data of the whole card without a password. Therefore, you should pay attention to content encryption during design to prevent damage.

Identify the data format.

3. The whole card is not partitioned. Once the password is checked correctly, data can be written or modified to any address.

Pay attention to appropriate data solidification and data content encryption to prevent unintentional destruction of data or illegal data changes.

4. After the password is verified correctly, it can be read. Therefore, during the design, the program should be able to prevent attackers from using illegal program interruptions,

You can directly read the password to steal the password.

SLE4442 card is now upgraded to sle5542 chip card

3. Introduction to sle4428 Carter

I. Introduction

Electrical Performance

  • 1024x8-bit EEPROM
  • Byte direct addressing
  • Unrecoverable write Protection
  • 1024-bit Protection
  • Serial three-line mark
  • End mark of data write operation
  • Bytes erased and then written at: standard value 25 ms
  • Minimum write erasure times: 10000
  • Data Retention Period: 10 Years
  • The contact structure and serial interface comply with the iso7816 synchronization protocol.

 

Confidentiality (Including password operation and curing Protection)

  • Two-byte user password.
  • Before the password is verified correctly, all data is readable and cannot be rewritten.
  • After checking that the password is correct, you can change the data, including the password.
  • Error counter. The initial value is 8. If the password verification fails once, the value is reduced by 1. If the counter value is 0, the card is locked automatically and the data can only be read, you cannot change the password or check the password again. If the password is correct once, it can be restored to the initial value of 8.
  • Each byte in the data area can be individually protected. After the write protection is performed, the content cannot be changed (that is, the data is solidified ).

Provides operation functions (See examples)

Write operation function: swr_4428 ()

Read operation function: srd_4428 ()

Write Data Synchronization protection: wrwpb_4428 ()

Read data and protection space: rdwpb_4428 ()

Card Test function: chk_4428 ()

Verification password function: csc_4428 ()

Password reading function: rsc_4428 ()

Change Password function: wsc_4428 ()

Read Password error count:
Rsct_4428 ()

Write protection bit function: pwr_4428 ()

 
Sle4428 card Introduction
I. Main Indicators

● 1024-byte EEPROM

● 1024-byte write Protection Zone (solidified data)

● 2-byte password, 8 error counts

● Temperature range:-35 ℃ ~ 80 ℃

● At least 100,000 write erase cycles

● Data retention period of at least 10 years


Ii. Storage zone allocation
  
See:



Iii. Function Description

1. The capacity of sle4428 is 1 Kbytes, and the address space ranges from 0 ~ 1023.

2. All data except the password can be read under any circumstances, and the password can be read after being checked correctly.

3. All data, including the password, can be written or changed after the correct password is checked.

4. All data can be written by byte. After the write protection, the data is solidified and cannot be changed under any circumstances.

5. There is a Password error counter. The URL is 1021. The initial value is 8. If the password verification fails once, 1 is subtracted. If

If the counter value is 0, the data on the whole card is locked and can only be read, cannot be written or changed, and the password cannot be verified.

If the value is not 0, only one check is correct and the counter is restored to the initial value.

6. The password is 2 bytes and the address is 1022 and 1023. There are a total of 216 combinations, before the password is verified correctly,

The result of reading these two addresses is "00" and cannot be written or changed. After the password is checked correctly, you can read or change the password.

Change the password until the power is disconnected.

7. unique code. Address 21 ~ 26 is the card user code, which is the only user code in the world, to the maximum extent

To ensure the interests of users, this code can not be changed after being solidified and written.

8. Address 0 ~ 7, 21 ~ 26 it has been solidified by the manufacturer before leaving the factory and cannot be changed.


Iv. Notes

1. sle4428 has three security mechanisms: User Password, unique code, and fixed write. If the password is not checked correctly,

Data cannot be written. Once written data is protected (solidified), it cannot be changed. Use unique code as the system

The ID of the IC card to prevent counterfeit cards of the same model from entering the system.

2. You can read the data of the entire card without a password on the sle4428 card. Therefore, you must pay attention to the content encryption during design to prevent cracking.

The bad person identifies the data format.

3. The whole card is not partitioned. Once the password is checked correctly, data can be written or modified to any address.

Pay attention to the appropriate solidification of data and data content encryption, in order to prevent unintentional destruction of data or illegal changes to data.

4. After the password is verified correctly, it can be read. Therefore, during the design, the program should be able to prevent the Destroyer from using illegal interrupted program operations.

To steal the password.

 

4. Remarks area of the card reader

User remarks

You can write comments up to bytes in the eeprom of the reader (Note: it is the remarks of the card reader, not the remarks of the card.

In the remarks area, you can write information such as the reader ID, company name, Department name, user name, date, and time.

For more information, see functions:

Write note area: swr_eeprom ()

Read note area: srd_eeprom ()
The card reader also has an EEPROM storage space and corresponding read/write functions and password verification, but the operations on the card reader are not common unless you need to verify the password before using the card reader, to ensure the dedicated feature of the card reader.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.