public void setupMIC ( byte [ ] type1 , byte [ ] type2 ) throws GeneralSecurityException , IOException { byte [ ] sk = this . masterKey ; if ( sk == null ) { return ; } MessageDigest mac = Crypto . getHMACT64 ( sk ) ; mac . update ( type1 ) ; mac . update ( type2 ) ; byte [ ] type3 = toByteArray ( ) ; mac . update ( type3 ) ; setMic ( mac . digest ( ) ) ; }
Sets the MIC