Files
Include/SELkLockId.h
T
Dario Sassi 7c112f09ca Include :
- aggiornamento prototipi.
2019-05-13 09:31:11 +00:00

40 lines
1.6 KiB
C++

//----------------------------------------------------------------------------
// EgalTech 2014-2015
//----------------------------------------------------------------------------
// File : SELkLockId.cpp Data : 27.07.15 Versione : 1.6g8
// Contenuto : Dichiarazione funzioni per gestione/calcolo Id protezione,
// da macchina o da chiave hardware.
//
//
// Modifiche : 10.09.14 DS Creazione modulo.
//
//
//----------------------------------------------------------------------------
#pragma once
#include <string>
//-------------------------------------------------------------------------------
// Imposto il tipo di protezione
bool SetLockType( int nType) ;
// Recupero l'identificativo in chiaro della protezione
bool GetLockId( std::string& sLockId) ;
// Recupero l'identificativo cifrato della protezione
bool GetLockId2( std::string& sLockId) ;
// conversioni
bool ConvertLockIdToLockId2( const std::string& sLockId, std::string& sLockId2) ;
bool ConvertLockId2ToLockId( const std::string& sLockId2, std::string& sLockId) ;
bool ConvertLockIdToScramKey( const std::string& sLockId, std::string& sScramKey) ;
bool ConvertLockId2ToScramKey( const std::string& sLockId2, std::string& sScramKey) ;
// Serial Number della chiave hw
bool GetLockSN( int& nLockSN) ;
//-------------------------- Constants ----------------------------------------
// Tipo di protezione
const int KEY_LOCK_TYPE_ANY = 0 ;
const int KEY_LOCK_TYPE_SW = 1 ;
const int KEY_LOCK_TYPE_HW = 2 ;
// Inizio Id protezione hw
const std::string KEY_LOCK_HW_START = "EGTECH" ;