2. Convert hash result to hex clear string (ascii).
3. Convert asciiMAC to decimal bytes
4. Convert decimalMAC to HEX
5. Get digest from PUSH headers.
6. Compare calculated digest with the digest extracted from push headers.
7. If both digests are comparable then AUTHENTICATION success.
Simple example
This example creates an Internet account with the name PROV_NAP with GPRS as bearer. The authentication username will be "foo" and the password will be "bar".
The PIN code for this document is "1111".
00//TransactionID
06//PDUType:Push
2F//HeadersLength
1F//ValueLength,LongLengthIndicator
2D//ValueLength,
B6//MediaType:application/vnd.wap.connectivity-wbxml(June2000)
91//SECParameter
81//Value:USERPIN(0x01),IsShortInteger(0x80)
92//MACParameter
33616534313332356638
66363762613763666665
37336235326233623661
62336333303130313637
//MACValue:"3ae41325f8f67ba7cffe73b52b3b6ab3c301016"
//AssociatedPINis"1111"
00//Endofstring
//Endofheaders,StartofWBXML
02//WBXMLVersion1.2
0B//DocumentPublicIdentifier:-//WAPFORUM//DTDPROV1.0//EN
6A//Charset:UTF-8
00//StringTableLength:00
45//<wap-provisioning>element,contentincluded
C6//<characteristic>element,attributesincluded,content//included
55//attribute,type="NAPDEF"
01//endoftag
87//<parm/>element,attributesincluded
11//attribute,name="NAPID"
06//attribute,value=
03//inlinestring
50524F565F4E4150 //"PROV_NAP"
00//endofstring
01//endoftagand<parm/>element
87//<parm/>element,attributesincluded
10//attribute,name="BEARER"
06//attribute,value=
AB//"GSM-GPRS"
01//endoftagand<parm/>element
87//<parm/>element,attributesincluded
07//attribute,name="NAME"
06//attribute,value=
03//inlinestring
50524F565F4E4150 //"PROV_NAP"
00//endofstring
01//endoftagand<parm/>element
C6//<characteristic>element,attributesincluded,content//included
5A//attribute,type="NAPAUTHINFO"
01//Endoftag
87//<parm/>element,attributesincluded
0C//attribute,name="AUTHTYPE"
06//attribute,value=
9A//"PAP"
01//endoftagand<parm/>element
87//<parm/>element,attributesincluded
0D//attribute,name="AUTHNAME"
06//attribute,value=
03//inlinestring
666F6F //"foo"
00//endofstring
01//endoftagand<parm/>element
87//<parm/>element,attributesincluded
0E//attribute,name="AUTHSECRET"
06//attribute,value=
03//inlinestring
626172 //"bar"
00//endofstring
01//endoftagand<parm/>element
01//</characteristic>tag,endofelement
01//</characteristic>tag,endofelement
01//</wap-provisioning>tag,endofelement
Labels: push-auth

0 Comments:
Post a Comment
Subscribe to Post Comments [Atom]
<< Home