Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Init ospd with a path to store files with scan info #266

Merged
merged 3 commits into from
Jun 4, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
- Add details parameter to get_vt_iterator(). [#215](https://github.com/greenbone/ospd-openvas/pull/215)
- Add [pontos](https://github.com/greenbone/pontos) as dev dependency for
managing the version information in ospd-openvas [#238](https://github.com/greenbone/ospd-openvas/pull/238)
- Pass store directory to OSPDaemon init [#266](https://github.com/greenbone/ospd-openvas/pull/266)

### Changed
- Less strict checks for the nvti cache version
Expand Down
26 changes: 26 additions & 0 deletions docs/ospd-openvas.8
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,20 @@ Start the scan with the given niceness. Default 10
Time in hours a scan is stored before being considered forgotten and being delete from
the scan table. Default 0, disabled.

.TP
.BI "--max-scans "VALUE
Max. amount of parallel task that can be started. Default 0, disabled.

.TP
.BI "--min-free-mem-scan-queue "MB
Minimum free memory in MB required to run the scan. If no enough free memory is
available, the scan is queued. Default 0, disabled.

.TP
.BI "--max-queued-scans "VALUE
Maximum number allowed of queued scans before starting to reject new scans.
Default 0, disabled.

.SH THE CONFIGURATION FILE

The default
Expand Down Expand Up @@ -141,6 +155,18 @@ Set a timeout on socket operations. Default 10 seconds
Time in hours a scan is stored before being considered forgotten and being delete from
the scan table. Default 0, disabled.

.IP max_scans
Max. amount of parallel task that can be started. Default 0, disabled.

.IP min_free_mem_scan_queue
Minimum free memory in MB required to run the scan. If no enough free memory is
available, the scan is queued. Default 0, disabled.

.IP max_queued_scans
Maximum number allowed of queued scans before starting to reject new scans.
Default 0, disabled.


.SH MORE INFORMATION ABOUT Greenbone Vulnerability Management

The canonical places where you will find more information
Expand Down
5 changes: 4 additions & 1 deletion ospd_openvas/daemon.py
Original file line number Diff line number Diff line change
Expand Up @@ -308,7 +308,10 @@ def __init__(
self.nvti = NVTICache(self.main_db)

super().__init__(
customvtfilter=OpenVasVtsFilter(self.nvti), storage=dict, **kwargs
customvtfilter=OpenVasVtsFilter(self.nvti),
storage=dict,
file_storage_dir=lock_file_dir,
**kwargs,
)

self.server_version = __version__
Expand Down