Upload
groovey9040
View
227
Download
0
Embed Size (px)
Citation preview
8/3/2019 card-data
1/5
www.hidcorp.com 2006 HID Corporation. All rights reserved.1
Understanding Card Data Formats
Wiegand
FormatThe term Wiegand is applied to several characteristics related to access control readers and cards. Unortunately, the wordis used carelessly and can lead to unnecessary conusion. Here are the basics.
Wiegand is:
1. A specifc reader-to-card interace
2. A specifc binary reader-to-controller interace
3. An electronic signal carrying data
4. The standard 26-bit binary card data ormat
5. An electromagnetic eect
6. A card technology
For the purposes o this white paper, we will address items 2 and 4.
(NOTE: There are additional card/reader attributes that are also described by the term, Wiegand.)
When HID customers say, Wiegand ormat, they typically reer to the general concept o security card data encoding. But
be aware that the term, Wiegand ormat, is also oten understood to mean the standard 26-bit ormat, which is a very specifc
arrangement o binary card data. Some basic acts:
Aformatdescribeswhatanumbermeans,orhowanumberisused.Theformatisnotthenumberitself,
Thenumberofbitsdoesnotindicatetheformatexceptforstandard26-bit.Forexample,thereareover100
dierent 34-bit ormats alone.
Withinagivenbitlength(34-bit,37-bit,etc.),thesizeandlocationofeachdataelementmaychange.Forexample:
o One 34-bit ormat may have an 8-bit Facility Code starting with bit #2.
o Another 34-bit Facility Code may be 12 bits starting with bit # 21.
Thecapabilityoftheaccesscontrolpanelwilldictatewhatformatswillandwillnotwork.
I I see a string o numbers, 19495981699 it may mean nothing. I you describe it as a phone number in the United States,then it is immediately understood that 949 is the area code, etc. Knowledge o the ormat allows you to decode the data. It
alwaysappearsintheformat,(xxx)yyy-zzzz,becausetelephonecompanyswitchingequipmentspeciesitexistinthisformat.
The telephone company has maintained this ormat or many years and migrated to it slowly over the years adding numbers in
groups.Securityequipmenthassimilarformatdemandshoweverthesecurityindustrydoesnotwanttheformatknownand
theyoftenchangetheformatstokeepthechangescondential.
Allspeciccardformatsareidenticalinboth125kHzProxand13.56MHziCLASS cards. This ensures that any controller
capableofunderstandingdatafrom125kHzcardsandreaderswillalsoseamlesslyworkwith13.56MHzcardsandreaders.
The Standard 26-Bit FormatThe ormat in which a card is programmed is determined by the data pattern that will be compatible with the access control
panel. All HID credentials (card, obs, tags, etc.) can be programmed with the standard 26-bit card data ormat.
The Standard 26-bit Format is an Open Format.
AnOpen Format means that anyone can buy HID cards in a specifc ormat and that specifc ormat description is publicly
available. The 26-bit ormat is a widely used industry standard and is available to all HID customers. Almost all access
control systems accept the standard 26-bit ormat. 26-bit originated with true Wiegand swipe card technology.
Technology Basics White Paper
1
8/3/2019 card-data
2/5
www.hidcorp.com 2006 HID Corporation. All rights reserved.2
TheHIDorderingcodenumberfortheStandard26-bitformatisH10301.
H10301has255possiblefacilitycodesfromoneto255.Therecanbeupto65,535cardIDnumbers,fromoneto65,535,
perfacilitycode.Thetotalnumberofcardsthatcanusetheentirerangewithoutduplicationis16,711,425.Thereareno
restrictions on the use o this ormat. It is not documented by HID and HID does not restrict duplication o card numbers.
HIDproducesandmanagesover1,000othercarddataformats,butallofthemsharethesamefundamentalconceptsasthe
26-bitformat.Othercardmanufacturersalsohaveunique,proprietaryformats.
H10301describesbinaryencodeddata.Theformatisrepresentedinthenextgure:
Figure 1: 26-Bit Wiegand Public Format
ThemaximumFacilityCodeis255becauseifalleightFacilityCodebitsaresettoones,theyequal255decimal.
ThemaximumCardNumberis65,535becausewhenallsixteenCardNumbereldbitsareones,itequalsdecimal
65,535.
ANOTEONPARITY:Aparitybitisusedasaverysimplequalitycheckfortheaccuracyofthetransmittedbinarydata.The
designer o the ormat program will decide i each parity bit should be even or odd. A selected group o data bits will be
united with one parity bit, and the total number o bits should result in either an even or odd number.
Intheexampleabove,theleadingparitybit(even)islinkedtotherst12databits.Ifthe12databitsresultinanoddnumber,theparitybitissettoonetomakethe13-bittotalcomeouteven.Thenal13bitsaresimilarlysettoanoddtotal.
Other Hypothetical FormatsTofurtherclarifyhowformatsmaybeorganized,wepresenttwoadditionalhypotheticalexamples.
NOTE:Sinceactualformatsdorequireavaryingdegreeofsecurity,wewillonlypresenthypotheticalexampleswiththe
exceptionofstandard26-bit.
"Standard" 26-Bit Wiegand Format
Parity Configuration
Leading Parity Bit (Even)
Facillity Code (8 Bits)
First 13 Bits (12 data + 1 Parity)
Last 13 Bits (12 data + 1 Parity)
Trailing Parity Bit (Odd)
Card Number (16 bits)
P FFFFFFFF NNNNNNNNNNNNNNNN P
PFFFFFFFFNNNN NNNNNNNNNNNNP
8/3/2019 card-data
3/5
www.hidcorp.com 2006 HID Corporation. All rights reserved.3
Inthestandard26-bitformat,H10301,ortheprogrammableeldisspeciedastheFacilityCode.Theincrementingeld
is called the Card Number. These data groupings can have many dierent names depending upon which ormat is under
discussion. The same name usually means something dierent rom ormat to ormat. Thereore, another hypothetical
formatcouldlooklikethis:
Figure 2: Hypothetical 36-Bit Card Data Format
TheLeadingParitybitcouldrelatetoonesubsetofthedatastringandtheSecondParitybitrelatetoanentirelydifferentsubset.ThisformatalsohaseldsnamedFacilityCodeandCardNumber,butifyoucompareittoH10301,itsformatisvery
different,andwouldprobablynotworkonacustomerssystemthatwassetupforH10301.
Thepersonwhocreatestheformatsuniqueeldnameshastheabilitytoassignthenamesaswell.Reviewthefollowing
hypothetical ormat:
Figure 3: Hypothetical 30-bit Card Data Format
This ormat has three parity bits, a fve-bit programmable feld called Job Number, another our-bit programmable feld called
RunCode,andan18-bitincrementingeldcalledEmployeeNumber.
Whentakinginformationfromacustomerabouttheirformat,itisimportanttoobtaintheexactvaluestheywantinthe
programmable felds. The customer, not HID, supplies this inormation.
Pleasenotethatcustomersoftenconfusetheterms,FacilityCodeandSiteCode.SomeformatshaveaeldcalledFacilityCodeandothershaveaSiteCode,whileothersmayhaveneitherorboth.Youmustbecertaintoutilizethecorrectterms
when ordering your cards.
Toavoidduplicatingcardsthatarealreadyinuseonasite,customersmustknowtheexistingcardnumbers.
Systeminstallerswillalsoneedtoknowtheformatname,andspeciceldinformationinordertosetuptheirsecuritypanels
and enroll cards. In act, it is almost impossible to batch enroll cards without these specifcs. HID always includes a Cross
ReferenceListwitheverycardorderthathastheformat,andallspeciccarddatalisted.HIDsalesordersandcardbox
labels also include this same inormation.
Leading Parity Bit
Second Parity Bit
Facillity Code (10 Bits)
Card # (24 Bits)
P P FFFFFFFFFF NNNNNNNNNNNNNNNNNNNNNNNN
3 Parity Bits
Job Number (5 Bits)
Employee # (18 Bits)
Run Code (4 Bits)
PPP JJJJJ RRRR NNNNNNNNNNNNNNNNNN
8/3/2019 card-data
4/5
www.hidcorp.com 2006 HID Corporation. All rights reserved.4
Corporate 1000HIDoffersauniquecarddataformatprogramnamedCorporate1000,wheretheenduserownstheuniqueformatandHID
guaranteesthatthecustomersformatwillnotbeduplicated.Furthermore,thecustomermustprovidewrittenauthorization
toHIDforanintegratorordistributor,etc.tobeabletopurchasethespeciedCorporate1000cardsfromHID.Thisgivesthecustomerabsolutecontroloverthemanufacture,distributionanddeliveryoftheirspeciccards.AdditionalCorporate1000
acts:
ThecustomersaccesscontrolpanelsmustbecapableofdecodingtheCorporate1000format.
AllCorporate1000formatsare35bitslongbutthedatawillbearrangedindifferentincrementsalongthat35-bit
string.Acardnumber,forexample,maybebrokenintothreeormorepartsandrandomlyspacedalongthestring.
ThisensuresuniquenessineveryCorporate1000format.
HIDcurrentlymanagesseveralhundreduniqueCorporate1000formatsandmanymorearestillreadilyavailable.
Aswithallotherformats,Corporate1000formatsareidenticalin125kHzProxand13.56MHziCLASScontactless
smart card technology.
The Wiegand Reader-to-Controller Interface
An interace defnes how two devices communicate with one another. Various HID readers can communicate with accesscontrol panels using a variety o well-established, industry-standard interaces including:
Wiegand
Serial(RS232,RS422,RS485)
Clock-and-Data(MagneticStripeTrack/2)AlsoknownasABAformat.
We will concentrate on the Wiegand interace because it is the most prominent industry interace or card access control.
The Wiegand interace consists o three conductors (wires) called Data Zero (usually green), Data One (usually white), and
DataReturn(usuallyblack).WheninstallersobtainanHIDreader,theyexpecttoseethesethreenamesontheconnection
points (terminals) or both the reader and the access control panel. All current standard HID reader types are available with a
Wiegand interace. The three wires carry Wiegand data, also called the Wiegand signal.
Sincethecarddataisbinary,thereadersimplyreceivestheradiofrequency(RF)datafromthecard,translatesitfromRFtoWiegand protocol and sends the complete binary string to the controller. Zeros travel on the green wire, ones on the white
wire and the controller combines the two strings o characters into the original set o binary data.
NOTE:Thereaderperformsnoprocessingorqualitycheckingofthedata.Itsimplyreceivesthe(RF)datafromthecardand
converts it to Wiegand protocol or immediate transmission to the controller.
Panel Format SettingsAccess control panels are built to reject card data that does not conorm to a specifc pre-defned ormat. Almost all panels
canusethe26-bitstandardformat(possiblyinadditiontothemanufacturersownproprietaryformats).Simplepanelsmight
use only one or two ormats, but more sophisticated panels are sotware confgurable and accept virtually all o the dierent
formats.Somecanevencreatecustomizedformats.Onceaformatisdetermined,thepanelisthencongured.Proximity
cardsmustbeorderedforusewiththatconguredformatandthecardmustbeprogrammedtoconformtothepanelsformat
in order to unction.
Thisone-wayowofsetupinformationfrompaneltocardisintentional.Itmakesitdifcultforanunauthorizedpersonwho
ndsaproximitycardtoknowwhereandhowtouseit.Evenapersonwiththetechnicalknowledgeandequipmentcannot
positively identiy the card ormat. The reason is due to the ormat inormation residing in the panel and not on the card. A
formatisnotanumberitisawayoflookingatanumber.Thecarddatamerelyconformstothepanelformat.
8/3/2019 card-data
5/5
www.hidcorp.com 2006 HID Corporation. All rights reserved.5
There are several essential pieces o inormation or placing HID card orders.
FormatName(Example:H10301.cdf)-HIDprogramscardsforourcustomersusinghundredsofexistingformats.
There is no deault ormat. The customer must always speciy to HID which ormat they want.
Programmableeldinformation-LookingagainatH10301.cdf,ithasaLeadingone-bitparityeld,followedbyan
eight-bitprogrammableeld,a16-bitincrementingeldandaTrailingParitybit.
Math Translations Decimal, Binary and HexadecimalWhile our everyday math is based on the decimal system, computers always use binary math. In binary, each column can
onlycontainaone(1)orzero(0).Binarydataisoftencombinedtogetherintoconvenientfour-bithexadecimal,orhexunits
calledNybbles.Hexvaluesaredisplayedas0F.
1 00000001 1
2 00000010 2
3 00000011 3
4 00000100 4
5 00000101 5
6 00000110 6
7 00000111 7
8 00001000 8
9 00001001 9
10 00001010 A
11 00001011 B
12 00001100 C
13 00001101 D
14 00001110 E
15 00001111 F16 00010000 10
32 00100000 20
64 01000000 40
100 01100100 64
Withhexadecimal,24bitscanberepresentedwithonlysixcharacters.
(1111) ( 1111) (1111) (1111) (1111) (1111) Groups o our bits called Nybbles.
F F F F F F
AFacilityCodeof255lookslikeFFinhex(15x16)+15=255
Anidenticationnumberof65535lookslikeFFFFinhex
(15x4096)+(15x256)+(15x16)+15=65535
Manypanelsusehexadecimalmathbecauseitiscompact,anddirectlyrepresentsbinary.HIDProxPro andMaxiProx
readerscanbeconguredtooutputdatatothepanelinhexviaRS232orRS422.