greenbone / gvm-tools

Remote control your Greenbone Community Edition or Greenbone Enterprise Appliance
https://greenbone.github.io/gvm-tools/
GNU General Public License v3.0
162 stars 89 forks source link

scripts/update-task-target.gmp TypeError: create_target() got an unexpected keyword argument 'port_list' #189

Closed renoPSC closed 4 years ago

renoPSC commented 5 years ago

Expected behavior

scripts/update-task-target.gmp updates target of task given UUID of task and CSV of hosts NOTE: this is a follow-up to issue 187 fixed in 188

Current behavior

scripts/update-task-target.gmp errors out with TypeError: create_target() got an unexpected keyword argument 'port_list'

user@host:$ gvm-pyshell tls --hostname 127.0.0.1 --port 9390 --gmp-username foo--gmp-password bar ./update-task-target.gmp ./host_file.csv "1ea79218-95ad-4a90-b933-e1c1a72a0cf9" Traceback (most recent call last): File "/usr/local/bin/gvm-pyshell", line 10, in sys.exit(main()) File "/usr/local/lib/python3.7/dist-packages/gvmtools/pyshell.py", line 325, in main load(script_name, global_vars) File "/usr/local/lib/python3.7/dist-packages/gvmtools/pyshell.py", line 352, in load exec(file, global_vars) # pylint: disable=exec-used File "", line 129, in File "", line 124, in main File "", line 100, in create_target_hosts File "", line 90, in copy_send_target TypeError: create_target() got an unexpected keyword argument 'port_list'

Steps to reproduce

  1. Confirmed I have a valid UUID
  2. Confirmed ./host_file.csv exists
  3. tried UUID with and without double quotes
  4. run command as shown above in "current behaviour"

GVM versions

gsa: (gsad --version) Greenbone Security Assistant 7.0.3

gvm: (gvmd --version) OpenVAS Manager 7.0.3

openvas-scanner: (openvassd --version) OpenVAS Scanner 5.1.3

gvm-libs: 9.0.3-1+b1

gvm-tools: (gvm-cli --version) gvm-cli 2.0.0.beta1. API version 1.0.0.beta2

Environment

Operating system: KALI 2019.1a

Installation method / source: (packages, source installation) Kali repos GVM via PIP3

Logfiles

bjoernricks commented 4 years ago

Should be fixed in the 1.0.0 release. Please feel free to re-open if this is still an issue.