《PBOC20之静态数据认证电子教案.doc》由会员分享,可在线阅读,更多相关《PBOC20之静态数据认证电子教案.doc(10页珍藏版)》请在taowenge.com淘文阁网|工程机械CAD图纸|机械工程制图|CAD装配图下载|SolidWorks_CaTia_CAD_UG_PROE_设计图分享下载上搜索。
1、Good is good, but better carries it.精益求精,善益求善。PBOC20之静态数据认证-静态数据认证过程前提:按GPO响应后得到AFL和AIP,读应用中的所有数据AFL:08010200100105001801020120010100AIP:7D00如:静态数据认证步骤:1. 取认证中心(CA)公钥如下为认证中心产生的8个公钥:根据读到的认证中心公钥索引(8F0108)得到CA公钥,本例索引为08,故CA=B61645EDFD5498FB246444037A0FA18C0F101EBD8EFA54573CE6E6A7FBF63ED21D66340852B0211
2、CF5EEF6A1CD989F66AF21A8EB19DBD8DBC3706D135363A0D683D046304F5A836BC1BC632821AFE7A2F75DA3C50AC74C545A754562204137169663CFCC0B06E67E2109EBA41BC67FF20CC8AC80D7B6EE1A95465B3B2657533EA56D92D539E5064360EA4850FED2D1BF2. 得到发卡行公钥1) 读发卡行公钥证书(90标签)90标签8190长度988431EF60935AD351A0BBAF1F38481699A875AB740E56BAC799D8
3、AA5848BC9545A58D83A3F1B2AED512A60D6B872526E151144092A9F4EDACF3C57BD316B7B775EA9C64DBD2A7266EF05DFBEB0B4D526F90C16CD60CF58F8E72C4A926293DA5445B4CE9912F0D927CFBBC383ED91447FAA32587239D77FE48A9A65AAB8EAB6C64CB1498BF1EFD7794931E7C19E259E92) 用CA公钥解发卡行公钥证书得6A02622500FF123000008301019001C2ABE763CD75D57DDCD
4、34CF632AA27F5E95A5204562C2D39E9460774C761B86573E9D4C1B5AC4DADA9F42F9217712B73D5A66E29EA8E0274085FF633CB8EBBFAFB13F8BC826384E1522FAB4FC4545818CB6F416585845E7E64B721A34BE48FAEF0B078DCBADEBE5FFA22A74713BF808F3F175982D7849A348EA46B8599ACF99D3) BC读发卡行公钥余项(92标签)9224FFABC8ECF62FE4B096949FAE88A331792873163B
5、ECD90D75D8F1570F47ED40F78690B7FB验证发卡行证书HASHHASHInput=02622500FF123000008301019001C2ABE763CD75D57DDCD34CF632AA27F5E95A5204562C2D39E9460774C761B86573E9D4C1B5AC4DADA9F42F9217712B73D5A66E29EA8E0274085FF633CB8EBBFAFB13F8BC826384E1522FAB4FC4545818CB6F416585845E7E64B721A34BE48FAEF0B078DCBADEBE5FFA22A747FFA
6、BC8ECF62FE4B096949FAE88A331792873163BECD90D75D8F1570F47ED40F78690B7FB03HASHOutput=13bf808f3f175982d7849a348ea46b8599acf99d对比Hash结果是否相等13BF808F3F175982D7849A348EA46B8599ACF99D相等,公钥验证成功4) 连接公钥得到完整的发卡行公钥IssPuKey=C2ABE763CD75D57DDCD34CF632AA27F5E95A5204562C2D39E9460774C761B86573E9D4C1B5AC4DADA9F42F92177
7、12B73D5A66E29EA8E0274085FF633CB8EBBFAFB13F8BC826384E1522FAB4FC4545818CB6F416585845E7E64B721A34BE48FAEF0B078DCBADEBE5FFA22A747FFABC8ECF62FE4B096949FAE88A331792873163BECD90D75D8F1570F47ED40F78690B7FB3. 验证静态认证数据:1) 读签名的静态认证数据(93标签)938190BC6A5E5D13D8E3C287CC5BE776DB03842526173021D4D70BEA14D68517CFA465A3
8、88301EFF9A44818BA8E55EF9C81731497476D703FE204589E322A351C047E94BB03C824700649835BC4BFE396102B34F03FA004333D1E0A449999BE25041A7B97C5F8EFBB3C415D83DF31FA4552A3255EAB6287D3BE0358FAD8EA4FDB48122859ACA701CAED8F038306D31FDBC9A982) 用发卡行公钥解签名的静态认证数据得6A0301DAC0BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB
9、BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB93818F18240E6C8C34FFBA20DB12888674E780FFBC验证发卡行证书HASHHASHInput=0301DAC0BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB
10、BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB5F25030701015F24033012315A0862250000000001475F3401009F0702FF008E10000000000000000041035E0342031F009F0D05D86004A8009F0E0500100000009F0F05D86804F8005F28020156(需要参加静态认证的记录,AFL中标记了)7D00(9F4A0182AIP被标记了,所以要参加认证)HASHOutput=93818f18240e6c8c34ffba20db12888674e780ff对比Hash结果是否相等93818F18240E6C8C34FFBA20DB12888674E780FF相等,静态数据认证成功-