1 #ifndef LS_CONFIGURATION_H
2 #define LS_CONFIGURATION_H
6 #pragma warning( push )
7 #pragma warning( disable : 4251 )
20 using ptr_t = std::shared_ptr<Configuration>;
36 const std::string& sharedKey,
37 const std::string& productCode,
38 const std::string& appName,
39 const std::string& appVersion,
207 std::string m_apiKey;
208 std::string m_sharedKey;
209 std::string m_productCode;
210 std::string m_customerAccount;
211 std::string m_appName;
212 std::string m_appVersion;
213 std::string m_userInfo;
214 std::string m_airGapPublicKey;
220 #pragma warning( pop )
#define LS_API
Macros that expands to dllexport, dllimport or nothing on non Windows platforms or in case of static ...
DeviceIDAlgorithm
Type of Device ID algorithm used by the SDK.
Class for configuring application.
const std::string & getHostName() const
Getter for Host Name.
std::shared_ptr< Configuration > ptr_t
bool isVM() const
Checker for whether the user is on a virtual machine.
const std::string & getIP() const
Getter for IP Address.
void setDeviceIdAlgorithm(DeviceIDAlgorithm algorithm)
Setter for DeviceIDAlgorithm.
const std::string & getMAC() const
Getter for MAC Address.
bool isCollectNetworkInfoEnabled() const
Checker for if collection of network information is enabled in ExtendedOptions.
long getNetworkTimeout() const
Getter for network timeout.
const std::string & getOsVersion() const
Getter for Operating System version.
uint32_t getGracePeriod() const
Getter for grace period.
CryptoProvider::ptr_t getCryptoProvider()
Getter for crypto provider.
const NetworkInfo & getNetworkInfo() const
Getter for Network Information.
const std::string & getUserInfo() const
Returns custom information to be passed along with all API requests.
bool isLoggingEnabled() const
Checker for if logging is enabled in ExtendedOptions.
const std::string & getApiKey() const
Getter for API key (UUID).
Configuration()=default
Constructor for internal needs, use Create instead.
void setUserInfo(const std::string &customInfo)
Set custom information to be passed to the backend with all API requests.
bool isGuardFileEnabled() const
Checker for whether guard file usage is enabled in ExtendedOptions.
void setHardwareID(const std::string &deviceId)
Setter for device id.
void setCustomerAccount(const std::string &accountCode)
Set customer group (account) code that is required for SSO.
const std::string & getHardwareID()
Getter for device id.
const std::string & getAlternateKey() const
Getter for alternate public key.
bool isNativeTLSEnabled() const
Checker for whether native TLS for curl enabled or not.
bool isSSLCheckEnabled() const
Checker for whether SSL certificate verification is enabled.
const std::string & getSharedKey() const
Getter for shared key.
bool isVMDetectionEnabled() const
Checker for whether Virtual Machine Detection is enabled.
const std::string & getSdkVersion() const
Getter for LicenseSpring SDK version.
const std::string & getAirGapPublicKey() const
Getter for air gap public key.
void setAirGapPublicKey(const std::string &key)
Setter for air gap public key.
const ProxySettings & getProxySettings() const
Getter for ProxySettings object.
const std::string & getAlternateServiceUrl() const
Getter for alternate service URL.
const std::string & getAppName() const
Getter for application name.
const std::wstring & getLicenseFilePath() const
This method is obsolete! Return license file path that was set through ExtendedOptions or empty strin...
const std::string & getProductCode() const
Getter for product code.
static ptr_t Create(const std::string &apiKey, const std::string &sharedKey, const std::string &productCode, const std::string &appName, const std::string &appVersion, const ExtendedOptions &extendedOptions=ExtendedOptions())
Creates shared pointer for configuration object.
void setNetworkTimeout(long timeoutValue)
Setter for network timeout.
uint32_t getLicenseSpringAPIVersion() const
Getter for LicenseSpring API version.
const std::string & getCustomerAccount() const
Returns customer group (account) code that is required for SSO.
const std::string & getAppVersion() const
Getter for application version.
const std::string & getDetectedVMName() const
Getter for hypervisor name, calls isVM first if not yet called.
std::shared_ptr< CryptoProvider > ptr_t
Class for storing useful settings that the Configuration object will inherit.
Class for storing a device's network information.
Class for storing settings when using a proxy server.