reducktion / socrates

PHP package to Validate and Extract information from National Identification Numbers.
MIT License
47 stars 4 forks source link

Implement Germany 🇩🇪 #47

Closed AlexOlival closed 4 years ago

AlexOlival commented 4 years ago

No solid leads or good official information was found on how to validate the German Personal Identification Number.

Help is needed to implement it, if possible.

bofalke commented 4 years ago

Hi, i live in Germany and we built a validator once based on the information from this Project:

https://github.com/martyshka/PIDV/blob/master/src/Validator/DE.php

The personal identity number (German: Steueridentifikationsnummer) is the German national identification number.

  • 11 digits exactly
  • first digit can not be 0
  • the last digit is Checksum

There is also some more detailed information on wikipedia:https://de.wikipedia.org/wiki/Steuerliche_Identifikationsnummer#Aufbau_der_Identifikationsnummer

I can try and translate it if you like.

AlexOlival commented 4 years ago

Great job!

We can later implement this, but if you're up for the challenge how about if you implement the validator (and the extractor if it makes sense)? :wink:

@SLourenco and @afbernardino we just found Germany! :de:

bofalke commented 4 years ago

I can try to setup the Validator, i am not sure about the Extractor though. Will have a closer look into this and give you some feedback afterwards (:

bofalke commented 4 years ago

The 'Personal Identification Number' in germany is actually a Tax ID so unfortunately there are no additional information retrievable from this ID.

The official website for that topic can be found here

The Federal Central Tax Office is storing personal information like date of birth, name, gender and so on alongside the Id.

AlexOlival commented 4 years ago

Yeah, part of the reason that we left Germany unimplemented is because it wasn't clear which, if any, of the numbers used was the "Personal Identificational" one... :frowning_face:

bofalke commented 4 years ago

Yeah they changed the identification process somewhere around 2007 due to some specification from the EU. But if you like i will try to implement the Validator

AlexOlival commented 4 years ago

We first need to be extra sure of what is considered the ID for Germany. From my and @JoaoFSCruz experience researching for this package, the definition can get a bit tricky :sweat_smile:

AlexOlival commented 4 years ago

You can go ahead and open a PR! Make sure to target the release-1.3.0 branch