How to generate unique serials?

  • Posts: 98
  • Thank you received: 3
11 years 6 months ago #67564

Hi,

So I bought HikaSerial and I'm now trying add the new facility into my workflow. What I want to do is this:

- issue a unique activation key with each licence purchased thru HikaShop

- in my own activation page verify the key and associate it with a seat number generated by my software from the characteristics of the PC on which the software is installed. i.e. I need to know which table contains the order - key data and if I can add a seat number field.

Regarding unique activation keys my question is - are the random keys unique? I don't want to use sequential keys because it's a bit obvious to a customer who orders 2 licences how to activate a 3rd one. An obfuscated sequential system would be better.

Conrad

Please Log in or Create an account to join the conversation.

  • Posts: 25997
  • Thank you received: 4004
  • MODERATOR
11 years 6 months ago #67568

Hi,

The random generator does not check if the keys are real unique.
You can made a copy of the random generator in order to create a new random-unique generator.

The idea is to generate more serials than necessary and make a request in the database in order to check if all generated serials are not yet generated.
If there are some existing serials, just remove them from the list and use the N first non-existing serials.

Serials are stored in the table #__hikaserial_serial
The column serial_order_id is the order_id from #__hikashop_order.
The column serial_data contains your key.
The column serial_extradata contains extra data information (which have been serialized).

Regards,
Jerome


Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.

Please Log in or Create an account to join the conversation.

Moderators: Obsidev
Time to create page: 0.057 seconds
Powered by Kunena Forum