diff --git a/src/CPE/cpe_session.c b/src/CPE/cpe_session.c index f3c1dfe25d..691b8d6362 100644 --- a/src/CPE/cpe_session.c +++ b/src/CPE/cpe_session.c @@ -114,7 +114,9 @@ struct oval_agent_session *cpe_session_lookup_oval_session(struct cpe_session *c return NULL; } - session = oval_agent_new_session(oval_model, prefixed_href); + char *base_name = oscap_basename(prefixed_href); + session = oval_agent_new_session(oval_model, base_name); + free(base_name); if (session == NULL) { oscap_seterr(OSCAP_EFAMILY_OSCAP, "Cannot create OVAL session for '%s' for CPE applicability checking", prefixed_href); return NULL;