I've written a small test application which just calls VMProtectActivateLicense with the entered activation code, and returns the result.
I've also created a product and an activation code for one activation on the weblm.vmpsoft.com test server.
Activating the generated code works fine, even if called multiple times on the same PC.
When called on another PC it fails, because the code is already in use.
That's perfectly fine.
Now I did the same thing with my copy of WebLM, but it behaved differently.
Activation worked once, and additional activations on the same hardware fail.
This is a part of the query that's executed by WebLM when checking if there is already an existing license for an activation code, thus the activation count doesn't need to be increased:
Code: Select all
FROM vmp_hwdata h
LEFT JOIN vmp_licenses l ON h.licenseid = l.id
WHERE l.activationid = '1603'
AND l.blocked = '0'
AND h.value
IN ( 593995064 , -598438031 , -2011063309 , -1054116846, 529625838 )
That's because the creation script...
Code: Select all
mysql_query("CREATE TABLE {$DB_PREFIX}hwdata (
id int primary key auto_increment,
licenseid int,
type int,
value int unsigned
I've now simply changed the field type to signed, and multiple activations work fine now.