I have a question about the RPMB rollback protection counter, according to the RPMB specification, when a write operation is issued to the RPMB partition, this partition will compare a physical counter (inside this partition) to the counter that the write operation has, if it is equal, then continue the next check (HMAC,etc). If the write operation is validated, this physical counter will increase by 1. Now here comes my question:
- Is this a global counter for the whole RPMB patition ? Or everytime when we create a small chunk inside, then RPMB patition will have a counter associated to it ?
- What is the size of this counter ? What will happen if there are too many write operations and then overflows?
- If overflow happened, will the RPMB protect still valid ? Or no more write operations are allowed ?
- Is there is way to factory reset the RPMB partition (like the normal user partition in Android ?)
Thanks.
After all, I got the answer: