Topics
:Overview
Constants
Type Definitions
Encryption Rules
Functions
The software registration generator is used to generate proprietary software registration numbers using A-C-E level one encryption and a magic number sequence. This implementation uses a standard encryption method offset by a magic number polynomial allowing you to create and maintain proprietary registration codes.
Constants used to configure the software registration generator. If any of these constants are modified the software registration numbers will be changed. This will effect all applications using the srnGenerator class to generate registration codes.
const double srnVersionNumber = 4000.101; // Current version const char srnSegmentSeparator = '-'; // Separator character const unsigned srnMaxStringLength = 255; // Max chars per string const unsigned srnTableSize = 256; // Table size for magic numbers const unsigned srnMaxNameChars = 8; // Max chars per program name const srnIntType srnPolynomial = 0xbca44105; // Magic number polynomial
* Change the magic number polynomial constant to generate proprietary registration codes.
srnIntType - Integer type use for magic numbers.
A-C-E Level One Alphanumeric Encryption Rules
A-C-E level one encryption is used to generate an alphanumeric code sequence based on a character string. There are a total of 11 encryption rules with a special rule for non-alphanumeric characters.
srnGenerator::srnGenerator()
srnGenerator::~srnGenerator()
srnGenerator::GenMagicNumber()
srnGenerator::GenRegString()
srnGenerator::GetMagicNumber()
srnGenerator::GetRegCode()
srnGenerator::GetRegString()
srnGenerator::Validate()
srnGenerator::srnGenerator()
- Default class constructor.srnGenerator::srnGenerator(const char *pname, const char *user_name)
- Class constructor used to construct an srnGenerator object and generate a registration code based on an arbitrary program and user name string.srnGenerator::srnGenerator(const srnGenerator &ob)
- Class copy constructor.srnGenerator srnGenerator::operator=(const srnGenerator &ob)
- Assignment operator.srnGenerator::~srnGenerator()
- Class destructor.srnIntType srnGenerator::GenMagicNumber(const char *pname, const char *user_name)
- Public member function used to generate a magic number based on the program's name. This function is called by the srnGenerator::GenRegString() functions but can be used by the application to validate magic numbers.void srnGenerator::GenRegString(const char *pname, const char *user_name)
- Public member function used to generate a registration code based on an arbitrary program and user name string.srnIntType srnGenerator::GetMagicNumber()
- Public member function that returns the magic number sequence currently in use.char *srnGenerator::GetRegCode()
- Public member function that returns a registration code containing the registration string, segment separator, and magic number sequence.char *srnGenerator::GetRegString()
- Public member function that returns the registration string.int srnGenerator::Validate(const char *regCode, const char *pname,const char *user_name)
- Public member function used to validate a software registration string and magic number. Returns true if the software registration string matches the program name, user name, and the magic number sequence.
End Of Document |