Rename wrong_guess_counter to failure_counter
I named the file "wrong_guess_counter" with the intention that it count only wrong guesses, not other failures. That would be ideal; however, unfortunately the error codes from Weaver and Gatekeeper do not always differentiate wrong guesses from other failures. Therefore, the counter does count other failures, because not rate-limiting them would make the software rate-limiter ineffective on many devices. Therefore, rename the file to "failure_counter". Update code and comments accordingly. No functional change except the name of the file. Note that since "failure_counter" is a less specific name anyway, this still leaves the door open to changing exactly what types of failures are counted in the future, including making it precisely count wrong guesses as was my original intent. Since this change touches the SyntheticPasswordManager class comment, also reformat that comment to be compatible with google-java-format. Test: atest FrameworksServicesTests:com.android.server.locksettings Bug: 395976735 Flag: android.security.software_ratelimiter Change-Id: I3ec9d412b70e32530acfa1352cedefed6ff29f25
Loading
Please register or sign in to comment