How to get started with magnetic stripe cards?

I am new to magnetic stripe cards. But if I have no idea about the structure of these cards, I also can not develop software for them.

Search a lot, gave me only this information:

These cards have 3 different tracks with Track-1, Track-2 and Track-3 in the black bar. And the data density on each track is different from the others.

Questions I have:

  • Is there a difference between a Mag-Stripe card reader and a writer? Or, as a smart card reader, does the reader write too?

  • Are all readers [/ writers] able to read [/ write on] all three tracks by default, and we choose which track is our goal in the program? or some readers [/ writers] for Track-1, some others for Track-2 and some others for Track-3? In other words, does the device require three different heads (is it a head?) To work with different tracks or one head for all three tracks?

  • Are these three tracks readable and writable, and some read-only?

  • Do we need new cards to write data to them, or can we clear an already used card and transfer new data to its tracks?

  • There is a device named Encoder in the list of devices for the Mag-Stripe card. What is this encoder for? What is the difference between Encoder and Reader or Writer?

  • Why are the data density and data type (alphanumeric) different for different tracks?

  • Any tool, document, specification, standard, library or tutorial to get started?

+6
source share
1 answer

Firstly, you will want to familiarize yourself with the ISO-7811 and ISO-7812 magnetic card standards.

Then you need to learn how to connect the minimum working example (MWE). Fortunately, readers are easy to read , and you can simply connect them directly to something like Arduino.

For at least one example, the format for bank cards:

% "ASCII string on track 1" ?; "ACSII string on track 2" ?; "ASCII line on track 3"?

This is just the serial stream that is provided, so the β€œpackages” will be different for different types of cards. Since this is just a reader, process all data read-only.

You can also find some existing code examples for extracting data from a map .

You can also find "blank" cards on SparkFun , but you will need to add some more money to customize the author . In addition, currently all types of cards for cards with magnetic cards have security functions, including universities, credit cards, etc. Therefore, parts of magnetic strips are difficult to read or read-only, etc.

If you plan to do something shadowy, these tools will not work, and rightly so.

If you plan to create your own security system for a laboratory or school, these cards are easily cloned and cracked by an intelligent person.

If you're just trying to learn a new topic, this tip will be helpful.

Hooray!

+7
source

Source: https://habr.com/ru/post/985062/


All Articles