Open SCAP Library
Loading...
Searching...
No Matches
ds_sds_session.h
1/*
2 * Copyright 2014 Red Hat Inc., Durham, North Carolina.
3 * All Rights Reserved.
4 *
5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Lesser General Public
7 * License as published by the Free Software Foundation; either
8 * version 2.1 of the License, or (at your option) any later version.
9 *
10 * This library is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * Lesser General Public License for more details.
14 *
15 * You should have received a copy of the GNU Lesser General Public
16 * License along with this library; if not, write to the Free Software
17 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
18 *
19 * Author:
20 * Šimon Lukašík
21 */
22#ifndef DS_SDS_SESSION_H
23#define DS_SDS_SESSION_H
24
25#ifdef HAVE_CONFIG_H
26#include <config.h>
27#endif
28
29#include "oscap.h"
30#include "oscap_source.h"
31#include "scap_ds.h"
32#include "oscap_download_cb.h"
33#include "oscap_export.h"
34
48struct ds_sds_session;
49
59
66OSCAP_API struct ds_sds_index *ds_sds_session_get_sds_idx(struct ds_sds_session *session);
67
72OSCAP_API void ds_sds_session_free(struct ds_sds_session *sds_session);
73
84OSCAP_API struct oscap_source *ds_sds_session_select_checklist(struct ds_sds_session *session, const char *datastream_id, const char *component_id, const char *benchmark_id);
85
94OSCAP_API struct oscap_source *ds_sds_session_select_tailoring(struct ds_sds_session *session, const char *component_id);
95
104OSCAP_API int ds_sds_session_set_datastream_id(struct ds_sds_session *session, const char *datastream_id);
105
112OSCAP_API const char *ds_sds_session_get_datastream_id(const struct ds_sds_session *session);
113
120OSCAP_API const char *ds_sds_session_get_checklist_id(const struct ds_sds_session *session);
121
128OSCAP_API const char *ds_sds_session_get_checklist_uri(const struct ds_sds_session *session);
129
141OSCAP_API struct oscap_source *ds_sds_session_get_component_by_href(struct ds_sds_session *session, const char *href);
142
151OSCAP_API bool ds_sds_session_can_register_component(struct ds_sds_session *session, const char *container_name, const char *component_id);
152
164OSCAP_API int ds_sds_session_register_component_with_dependencies(struct ds_sds_session *session, const char *container_name, const char *component_id, const char *target_filename);
165
172OSCAP_API int ds_sds_session_dump_component_files(struct ds_sds_session *session);
173
181OSCAP_API int ds_sds_session_set_target_dir(struct ds_sds_session *session, const char *target_dir);
182
193OSCAP_API void ds_sds_session_reset(struct ds_sds_session *session);
194
207OSCAP_API void ds_sds_session_configure_remote_resources(struct ds_sds_session *session, bool allowed, const char *local_files, download_progress_calllback_t callback);
208
209#endif
General OpenScap functions and types.
Open-scap Data Stream interface.
Retrieves iterator over all components inside the <extended-components> element.
Definition sds_index.c:209
Definition ds_sds_session.c:45
struct oscap_source * source
Source DataStream raw representation.
Definition ds_sds_session.c:46
OSCAP_API struct ds_sds_session * ds_sds_session_new_from_source(struct oscap_source *source)
Create new ds_sds_session from existing oscap_source.
Definition ds_sds_session.c:67
Definition oscap_source.c:66