Tuesday, April 09, 2013

US Social Security number(SSN), 美國社會安全號碼

原來SSN 係有兩個version:

A) Before 25th June, 2011

B) After 25th June, 2011

所以要原全正確的分析一定還要有發出日期 (issue date).

今天先說說 A) issued before 25th June, 2011.



1) AAA 區域號碼(area number)是前三位數字, 通常是申請者指定的收件地址州份 或在1973年之前的核發該卡片的機構代碼. 目前,有效的社會安全號碼中,區域號碼不會超過社會安全局所指定的上限772

2) GG 群組號碼(group number)為中間的兩位數字。它們與地理區域或其他資料並沒有任何相關性,僅是為了將號碼平均分配所設計的。群組號碼的範圍從01至99,並不按照數字大小的順序發行。為了管理上的原因,群組號碼依照以下順序發行:


3) SSSS 序號(serial number)。它們僅代表數字上的序號,在群組內的範圍從0001至9999。

Validation Rules:

1) 一定是 格式 AAA-GG-SSSS , 11位長

2) 任何數字群組不得全為 「0」(000-##-####、##-00-####、###-##-0000)

3) 區域號碼 (AAA) 不能是 000, 666 或者900到999

4) June 25, 2011之前區域號碼 (AAA)不得超過772

5) 不能落在  987-65-4320 到 987-65-4329 中 (保留作為廣告宣傳使用)

6) 社會安全局發佈了與區域號碼對應的最大群組號碼列表。由於群組號碼是依照一定的順序發行,因此可以藉由無效的群組號碼來辨識不合法的社會安全號碼。

Regular Expressions:

a) 以 Rules 1) 為標準:


b) 以 Rules 1), 2), 3), 4) 為標準


至於 5), 6)  就只好自行寫Code 了.

1 comment:

Jason Borne said...

We are a third party technical support service. Avast Customer Support is here to help you out with the whole procedure to Download Avast Antivirus online, We not only fix your Avast Support related issues but will guide with how to get started with your new Avast product once it gets installed successfully.We at Avast Tech Support provides service to protect your PC from potential online threats and external attacks like viruses, Trojans, malwares, spywares and phishing scams. And Avast Refund. Call on our Avast Phone Number.

Gmail Customer service is a third party technical support service for Gmail users when they face any technical issue or error in their Gmail account. Our Gmail Customer Support team solves issues like forgot Gmail account password, Gmail configuration or Sync issues, recover deleted emails and many more. Toll Free number (800) 986-9271
How you install or reinstall Office 365 or Office 2016 depends on whether your Office product is part of an Office for home or Office for business plan. If you're not sure what you have, see what office com setup products are included in each plan and then follow the steps for your product. The steps below also apply if you're installing a single, stand-alone Office application such as Access 2016 or Visio 2016. Need Help with office setup Enter Product Key? Call 1-800-000-0000 Toll Free
Norton Tech Support is a third party service provider and not in any way associated with Norton or any of its partner companies. We offer support for Norton products and sell subscription based additional warranty on computer and other peripheral devices. Call our Toll Free number 1 855 966 3855
Other Services
Norton Toll Free , Office-Setup , office.com/setup.