yes, You have to authenticate every sector before read/write on the block of that sector.Now you have execute Authentication command and you overwrite the block 3(sector trailer) that means the keys and access right has been change.
APDU For Authenticate a Block:-
The APDU format for Authenticate a block should be in following format.
CLA+ INS+ P1+ P2+ Lc+ (Version + AddMSB + AddLSB + KeyID + KeyNumber)
For Example :-
CLA = FF
INS = 86
P1 = 00
P2 = 01 (Block Number for Authentication)
Lc = 05 (Length of Data Field)
Data Field = Version + AddMSB + AddLSB + KeyId + KeyNumber
Version=01
AddMSB=00
AddLSB=05 (Block Number)
KeyID=60/61 (60 for keyA and 61 for keyB)
KeyNo= 00 (Key Slot number of reader)
FF 86 00 00 05 01 00 05 60 00