Unique Master Citizen Number

Unique Master Citizen Number (Croatian and Bosnian: Jedinstveni matični broj građana, JMBG, Macedonian: Единствен матичен број на граѓанинот, ЕМБГ, Serbian and Montenegrin: Јединствени матични број грађана, ЈМБГ, Jedinstveni matični broj građana, JMBG, Slovene: Enotna matična številka občana, EMŠO) is a unique identification number that was assigned to every citizen of former Yugoslav republics of the SFR Yugoslavia. Today it continues to be used in almost all of the countries that were created after the dissolution of YugoslaviaBosnia and Herzegovina, Montenegro, North Macedonia, Serbia and Slovenia use it in its original form, while Croatia has switched to a new identification number called the Personal Identification Number (Croatian: Osobni identifikacijski broj, OIB).

History

The JMBG was introduced on January 8, 1977[1] and applied to all citizens born before then and alive at the time. All six republics passed a law on the Unique Master Citizen Number.

Although the Republic of Croatia continued to use the JMBG after the independence[2] in 2002 the official name of the number there was changed to Matični broj građana (Master Citizen Number), acronym MBG.[3][4] Advocates of the right to privacy argued that JMBG was a piece of personally identifiable information that needed to be protected by information privacy law, mostly because it was unique and it included the person's date of birth. When the law to that effect was passed in 2003[5] it was no longer possible to use JMBG on identity cards, driver's licenses and similar documents. Even though law hid MBG from personal documents, various institutions (e.g. banks, schools, insurance companies ...) continued to demand citizens to give their MBG while signing various contracts, since MBG was natural unique identifier of each citizen. Seeing flaw of hiding MBG, on January 1, 2009 Croatia passed a new law[6] that introduced a different unique identifier called the Personal Identification Number (Croatian: Osobni identifikacijski broj, acronym OIB). The OIB consists of 11 randomly chosen digits and has been assigned to all Croatian citizens, companies registered in Croatia and foreign nationals residing in Croatia.[7] Although the OIB is in use, the MBG law remains in effect, and the MBG number is still issued. It is used for data coordination among government registries. MBG no longer appears on Croatian identity cards since 2003, instead OIB does, since 2013.

Composition

The number is made up of 13 digits in a form "DD MM YYY RR BBB K" (whitespaces are for convenience; digits are written without separation) where:

DD day of birth
MM month of birth
YYY last three digits of the year of birth
RR political region [8] of birth (for persons born before 1976, political region where they were first registered)
  • 01-08 foreign citizens [9] without citizenship of former Yugoslavia or succeeding countries (foreign citizens that receive citizenship also receive a 'regular' JMBG, not this 'foreigners only' one)
    • 01 - foreigners in Bosnia and Herzegovina
    • 02 - foreigners in Montenegro
    • 03 - foreigners in Croatia
    • 04 - foreigners in Macedonia
    • 05 - foreigners in Slovenia
    • 06 - foreigners in Central Serbia
    • 07 - foreigners in Vojvodina
    • 08 - foreigners in Kosovo
  • 00 and 09 naturalized citizens which had no republican citizenship[10]
  • 10-19 Bosnia and Herzegovina
  • 50-59 Slovenia (only 50 is used)
  • 60-69 (Citizens with temporary residence)
BBB unique number of the particular RR (represents a person within the DDMMYYYRR section in the particular municipality)
K - checksum

Checksum calculation

The checksum is calculated from the mapping DDMMYYYRRBBBK = abcdefghijklm, using the formula:

m = 11 (( 7*(a+g) + 6*(b+h) + 5*(c+i) + 4*(d+j) + 3*(e+k) + 2*(f+l) ) mod 11)
  • If m is between 1 and 9, the number K is the same as the number m
  • If m is 10 or 11 K becomes 0 (zero)

Note: there has been a small number of JMBGs that were assigned by valid authorities but which had an invalid checksum. Also, there are a few duplicate JMBGs in existence. The common anecdotal explanation for these is simple operator error. Reportedly these mistakes happened more often in the early 1990s. The chances of running into exceptions are reportedly low, and whether such exceptions justify questioning the use of JMBG as a unique identifier has not been scientifically analyzed.

Microsoft Excel formula

  • A1 - data (first 12 digits stored as text)
  • B1 - checksum calculation
  • C1 - full number with checksum
B1 = 11-(MOD((((7*(MID(A1,1,1)+MID(A1,7,1)))+(6*(MID(A1,2,1)+MID(A1,8,1)))+(5*(MID(A1,3,1)+MID(A1,9,1)))+(4*(MID(A1,4,1)+MID(A1,10,1)))+(3*(MID(A1,5,1)+MID(A1,11,1)))+(2*(MID(A1,6,1)+MID(A1,12,1))))),11))
C1 =CONCATENATE(A1,IF(B1<10,B1,0))

12


Ruby code for validation

def validjmbg jmbg
  
  len = jmbg.scan(/[0-9]/).size
  valid_chars = (jmbg =~ /^[0-9]+$/)
  
  if len != 13 or !valid_chars
    return false
  else
    j = jmbg.split(//).map(&:to_i)
    v = 11-((7*(j[0]+j[6])+
             6*(j[1]+j[7])+
             5*(j[2]+j[8])+
             4*(j[3]+j[9])+
             3*(j[4]+j[10])+
             2*(j[5]+j[11]))%11)
    v = 0 if v > 9        
    return v == j[12]
  end
end

Example

As an example, a valid identification number is 0101006500006; it is the number of the first male baby registered in Slovenia on January 1, 2006.

gollark: Although I suppose the disadvantage of this is that you may also want to authenticate the endpoint in some applicationy ways.
gollark: Some meshnetworky things do it at the internet layer.
gollark: Really, if the network stack were cooler, the encryption would be done at a lower layer and not just handed off to applications.
gollark: ALL data is to be encrypted.
gollark: Well, NOT being utterly secured would be uncool, and the only simpler thing would be, I don't know, Noise?

See also

References

  1. Law on the introduction of the Unique Master Citizen Number (»Official Gazette of SFRY«, No. 58/76., reg. 840., pp 1823. & 1824.) was published on 1976-12-31. The Law reached validity on 1977-01-08. Also the Article 12 of the Law gave a five years deadline for the introduction of the Unique Master Citizen Number
  2. Croatian Law on JMBG from 1992 - Zakon o matičnom broju - Narodne novine 1992-9 "Archived copy" (in Croatian). Archived from the original on June 10, 2015. Retrieved October 18, 2009.CS1 maint: archived copy as title (link)
  3. Changes in the Croatian Law on MBG from 2002 - Zakon o izmjenama i dopunama Zakona o matičnom broju - Narodne novine 2002-66 "Archived copy" (in Croatian). Archived from the original on November 5, 2015. Retrieved March 9, 2014.CS1 maint: archived copy as title (link)
  4. Full text of the Croatian master citizen number law at the Croatian Ministry of Interior Affairs (in Croatian)
  5. Croatian: Zakon o zaštiti osobnih podataka, Narodne novine 2003-103 "Archived copy" (in Croatian). Archived from the original on September 22, 2009. Retrieved October 18, 2009.CS1 maint: archived copy as title (link)
  6. Croatian: Zakon o osobnom identifikacijskom broju, Narodne novine 2008-60 "Archived copy" (in Croatian). Archived from the original on October 22, 2009. Retrieved May 5, 2010.CS1 maint: archived copy as title (link)
  7. OIB - Croatia Archived August 5, 2012, at the Wayback Machine
  8. Agreement on allocation of registry numbers for the Unique Master Citizen Number (»Official Gazette of SFRY«, No. 13/78., reg. 240.)
  9. Bylaw on the means for determining the Unique Master Foreigner Number (»Official Gazette of SFRY«, No. 43/80., reg. 705., pp 1431. & 1431.) published on 1980-08-01 and reached legal validity on 1980-08-09. This bylaw determined by its Article 5 the registry numbers for the Unique Master Foreigner Number.
  10. Registry numbers 00 and 09 were allocated to the Federal Secretariat for Internal Affairs and were used for naturalized citizens of the SFRY who had no republican citizenship. In Croatia, registry numbers 00 were to be used in case of filling out the quota of the registry number 03.
This article is issued from Wikipedia. The text is licensed under Creative Commons - Attribution - Sharealike. Additional terms may apply for the media files.