allow to override platform info
This commit is contained in:
@@ -77,6 +77,7 @@ METHOD(imc_attestation_state_t, get_pts, pts_t*,
|
|||||||
imc_state_t *imc_attestation_state_create(TNC_ConnectionID connection_id)
|
imc_state_t *imc_attestation_state_create(TNC_ConnectionID connection_id)
|
||||||
{
|
{
|
||||||
private_imc_attestation_state_t *this;
|
private_imc_attestation_state_t *this;
|
||||||
|
char *platform_info;
|
||||||
|
|
||||||
INIT(this,
|
INIT(this,
|
||||||
.public = {
|
.public = {
|
||||||
@@ -91,6 +92,13 @@ imc_state_t *imc_attestation_state_create(TNC_ConnectionID connection_id)
|
|||||||
.state = TNC_CONNECTION_STATE_CREATE,
|
.state = TNC_CONNECTION_STATE_CREATE,
|
||||||
.pts = pts_create(TRUE),
|
.pts = pts_create(TRUE),
|
||||||
);
|
);
|
||||||
|
|
||||||
|
platform_info = lib->settings->get_str(lib->settings,
|
||||||
|
"libimcv.plugins.imc-attestation.platform_info", NULL);
|
||||||
|
if (platform_info)
|
||||||
|
{
|
||||||
|
this->pts->set_platform_info(this->pts, platform_info);
|
||||||
|
}
|
||||||
|
|
||||||
return &this->public.interface;
|
return &this->public.interface;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user