Akheon23 / marketlicensing

Automatically exported from code.google.com/p/marketlicensing
Apache License 2.0
0 stars 0 forks source link

Serious bug in ServerManagedPolicy.java #58

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?

The ServerManagedPolicy.allowAccess() method is called once before checking 
with server from LicenseChecker.checkAccess(LicenseCheckerCallback callback) 
and once in the response handler when we receive response from server in 
LicenseValidator.handleResponse(int response, ResponseData rawData).

The first call is designed to check against the cached value (last response) to 
see if we should allow/deny based on the VT.

The server response handler code calls this method again resulting in the same 
allow/deny as if we never asked the server. This leads to ignoring the response 
from server and denying the access (since the cache is expired)

This is a serious bug and I am surprised this has not been addressed in a long 
time this code has been up.

Original issue reported on code.google.com by aquarim...@gmail.com on 21 Feb 2013 at 5:29