Re: [Openvas-discuss] Unable to add target with credentials using OMP (openvas: message 2 of 20)

2014-09-19 Thread John Lammers
Thanks Matthew.  I added -v and replaced all 127's with 128's.
Oddly, trying to add the target only produced 3 debug messages.

Here's the last 30 lines of openvasmd.log

event lsc_credential:MESSAGE:2014-09-16 22h28.42 UTC:7176: LSC Credential
8d8897ba-1aec-493c-b9eb-ba671703a36d has been created by admin
lib   rer:WARNING:2014-09-16 22h28.55 UTC:7203: Target source configuration
could not be loaded.
lib auth:   INFO:2014-09-17 14h59.53 utc:2026: Authentication configuration
not found.
event lsc_credential:MESSAGE:2014-09-17 18h12.50 UTC:17279: LSC Credential
8d8897ba-1aec-493c-b9eb-ba671703a36d has been modified by admin
lib   rer:WARNING:2014-09-17 18h13.39 UTC:17299: Target source
configuration could not be loaded.
event lsc_credential:MESSAGE:2014-09-17 20h16.11 UTC:17849: LSC Credential
8d8897ba-1aec-493c-b9eb-ba671703a36d has been deleted by admin
base gpgme:MESSAGE:2014-09-17 20h17.36 UTC:17864: Setting GnuPG homedir to
'/usr/local/var/lib/openvas/gnupg'
base gpgme:MESSAGE:2014-09-17 20h17.36 UTC:17864: Using OpenPGP engine
version '1.4.12'
event lsc_credential:MESSAGE:2014-09-17 20h17.36 UTC:17864: LSC Credential
d50da9b2-58a3-4c19-8194-a3d1d5d7ca14 has been created by admin
event report:MESSAGE:2014-09-17 20h32.10 UTC:17936: Report
581aaa3b-50b2-452d-9049-5a8e8feac34e has been deleted by admin
lib   rer:WARNING:2014-09-17 20h32.23 UTC:17946: Target source
configuration could not be loaded.
event lsc_credential:MESSAGE:2014-09-17 20h33.04 UTC:17958: LSC Credential
d50da9b2-58a3-4c19-8194-a3d1d5d7ca14 has been modified by admin
lib   rer:WARNING:2014-09-17 20h37.05 UTC:17985: Target source
configuration could not be loaded.
lib   rer:WARNING:2014-09-17 20h37.11 UTC:17988: Target source
configuration could not be loaded.
event target:MESSAGE:2014-09-17 20h37.19 UTC:17991: Target
f59262d8-cb92-4200-93f7-7b1277b89663 has been modified by admin
event target:MESSAGE:2014-09-17 20h37.44 UTC:18001: Target
f59262d8-cb92-4200-93f7-7b1277b89663 has been modified by admin
event lsc_credential:MESSAGE:2014-09-17 21h04.59 UTC:18206: LSC Credential
d50da9b2-58a3-4c19-8194-a3d1d5d7ca14 has been modified by admin
event task:MESSAGE:2014-09-17 21h18.22 UTC:18282: Status of task
 (94daaefb-89ec-401d-bdaa-096f3f744a48) has changed to New
event task:MESSAGE:2014-09-17 21h18.22 UTC:18282: Task
94daaefb-89ec-401d-bdaa-096f3f744a48 has been created by admin
event task:MESSAGE:2014-09-17 21h18.47 UTC:18287: Status of task Scan Johns
Test VM (94daaefb-89ec-401d-bdaa-096f3f744a48) has changed to Requested
event task:MESSAGE:2014-09-17 21h18.47 UTC:18287: Task
94daaefb-89ec-401d-bdaa-096f3f744a48 has been requested to start by admin
lib  serv:WARNING:2014-09-17 21h18.47 UTC:18287:Failed to gnutls_bye:
Error in the push function.
event task:MESSAGE:2014-09-17 21h18.48 UTC:18289: Status of task Scan Johns
Test VM (94daaefb-89ec-401d-bdaa-096f3f744a48) has changed to Running
event task:MESSAGE:2014-09-17 21h28.09 UTC:18289: Status of task Scan Johns
Test VM (94daaefb-89ec-401d-bdaa-096f3f744a48) has changed to Done
md   main:WARNING:2014-09-17 21h28.09 UTC:18289: sql_giveup: cannot start a
transaction within a transaction
lib auth:   INFO:2014-09-18 14h12.44 utc:2120: Authentication configuration
not found.
lib auth:   INFO:2014-09-18 14h29.48 utc:4103: Authentication configuration
not found.
lib  serv:  DEBUG:2014-09-18 14h32.03 utc:4176:Shook hands with peer.
lib  serv:  DEBUG:2014-09-18 14h32.03 utc:4176:Connected to server on
socket 10.
lib  serv:  DEBUG:2014-09-18 14h32.04 utc:4176:Shook hands with peer.


On Thu, Sep 18, 2014 at 3:55 AM, Matthew Mundell -
matthew.mund...@greenbone.net 
openvas.jel.06f3f67e71.matthew.mundell#greenbone@ob.0sg.net wrote:

  Any help would be much appreciated!

 The Manager logs (var/log/openvas/openvasmd.log) may indicate why the
 CREATE_TARGET is failing.  To enable logging: add -v to openvasmd, and
 replace 127 with 128 in etc/openvas/openvasmd_log.conf.

 --
 Greenbone Networks GmbH
 Neuer Graben 17, 49074 Osnabrueck, Germany | AG Osnabrueck, HR B 202460
 Executive Directors: Lukas Grunwald, Dr. Jan-Oliver Wagner



On Thu, Sep 18, 2014 at 3:55 AM, Matthew Mundell -
matthew.mund...@greenbone.net 
openvas.jel.06f3f67e71.matthew.mundell#greenbone@ob.0sg.net wrote:

  Any help would be much appreciated!

 The Manager logs (var/log/openvas/openvasmd.log) may indicate why the
 CREATE_TARGET is failing.  To enable logging: add -v to openvasmd, and
 replace 127 with 128 in etc/openvas/openvasmd_log.conf.

 --
 Greenbone Networks GmbH
 Neuer Graben 17, 49074 Osnabrueck, Germany | AG Osnabrueck, HR B 202460
 Executive Directors: Lukas Grunwald, Dr. Jan-Oliver Wagner


___
Openvas-discuss mailing list
Openvas-discuss@wald.intevation.org
https://lists.wald.intevation.org/cgi-bin/mailman/listinfo/openvas-discuss

[Openvas-discuss] Unable to add target with credentials using OMP

2014-09-18 Thread openvas . t422 . jel
Hi,

The Greenbone interface for OpenVAS 7 won't let me add a target with
credentials, so I'm trying to do it with OMP ... but I'm getting an error
message.

Would anyone be able to give me a workaround or tell me what I'm doing
wrong?  Maybe I just need another pair of eyes on it.  Here are the details:

# omp -X '
create_lsc_credential
nameOpenVAS SSH Key/name
loginroot/login
key
private-BEGIN RSA PRIVATE KEY-
XXX
XXX
XXX
-END RSA PRIVATE KEY-/private
publicssh-rsa
B3NzaC1yc2EDAQABAAABAQCjoIDsiJWLMtGp7dNa4KinMsJroEceK/DkgZmGcGInctAUDfj5wFoFMKjPsuPn9dvRWqG9NYJBazCAK6OeqowEGJ4FcAHDGRSn1JB27a4/8KlHopwikMXHlSIZPnSp/xeiKRnBV+MBN433CovigVsh0NsRyB4Wzl5Ng+NYNPP0TkoTc+gWwBO7icIbyeg4epqOVL9LjVlh2dpRNQpx9yyDatLOie8cgrvbsMiVG9gC/aqVSiXwW2cgyckEz+2mDmgCIGf7Spd3Fi5Ohw9zebn7aw54qoYaAbThEyeWRKwie/DvvO7U4RtAijHDzvQ48NOYFQx7nlqWyCoiY+SGtATZ
openvas@openvas/public
/key
/create_lsc_credential
'


This appears to succeed.

# cat bin/ompx
#!/bin/bash
omp -i -X $*/
# ompx get_lsc_credentials
get_lsc_credentials_response status_text=OK status=200
  lsc_credential id=d50da9b2-58a3-4c19-8194-a3d1d5d7ca14
owner
  nameadmin/name
/owner
nameOpenVAS SSH Key/name
comment/comment
creation_time2014-09-17T20:17:36Z/creation_time
modification_time2014-09-17T21:04:59Z/modification_time
writable1/writable
in_use0/in_use
permissions
  permission
nameEverything/name
  /permission
/permissions
user_tags
  count0/count
/user_tags
loginroot/login
typegen/type
  /lsc_credential
  ...


But adding a target with these credentials fails.

# omp -v -X '
create_target
nameJohns Test VM/name
hosts10.0.1.17/hosts
ssh_lsc_credential id=”d50da9b2-58a3-4c19-8194-a3d1d5d7ca14”
port22/port
/ssh_lsc_credential
/create_target
'
WARNING: Verbose mode may reveal passwords!
Will try to connect to host localhost, port 9390...
Sending to manager:
create_target
nameJohns Test VM/name
hosts10.0.1.17/hosts
ssh_lsc_credential id=”d50da9b2-58a3-4c19-8194-a3d1d5d7ca14”
port22/port
/ssh_lsc_credential
/create_target
lib   xml-Message:Error: Error on line 1 char 1: Document was empty or
contained only whitespace
(omp:3776): lib   xml-WARNING **:End error: Error on line 1 char 1:
Document was empty or contained only whitespace
Failed to read response.



I'm using the OpenVAS 7 virtual appliance, which I updated to the latest:

greenbone-security-assistant-5.0.3.tar.gz
openvas-cli-1.3.0.tar.gz
openvas-libraries-7.0.4.tar.gz
openvas-manager-5.0.4.tar.gz
openvas-scanner-4.0.3.tar.gz


Any help would be much appreciated!

--John
Sept 17, 2014
___
Openvas-discuss mailing list
Openvas-discuss@wald.intevation.org
https://lists.wald.intevation.org/cgi-bin/mailman/listinfo/openvas-discuss

Re: [Openvas-discuss] Unable to add target with credentials using OMP

2014-09-18 Thread Matthew Mundell
 Any help would be much appreciated!

The Manager logs (var/log/openvas/openvasmd.log) may indicate why the
CREATE_TARGET is failing.  To enable logging: add -v to openvasmd, and
replace 127 with 128 in etc/openvas/openvasmd_log.conf.

--
Greenbone Networks GmbH
Neuer Graben 17, 49074 Osnabrueck, Germany | AG Osnabrueck, HR B 202460
Executive Directors: Lukas Grunwald, Dr. Jan-Oliver Wagner
___
Openvas-discuss mailing list
Openvas-discuss@wald.intevation.org
https://lists.wald.intevation.org/cgi-bin/mailman/listinfo/openvas-discuss


Re: [Openvas-discuss] Unable to add target with credentials using OMP

2014-09-18 Thread Matthew Mundell
 Sending to manager:
 create_target
 nameJohns Test VM/name
 hosts10.0.1.17/hosts
 ssh_lsc_credential id=”d50da9b2-58a3-4c19-8194-a3d1d5d7ca14”

The UTF-8 quotation marks here seem to be the problem.  Try with a regular .

 port22/port
 /ssh_lsc_credential
 /create_target
 lib   xml-Message:Error: Error on line 1 char 1: Document was empty or
 contained only whitespace
 (omp:3776): lib   xml-WARNING **:End error: Error on line 1 char 1:
 Document was empty or contained only whitespace
 Failed to read response.

--
Greenbone Networks GmbH
Neuer Graben 17, 49074 Osnabrueck, Germany | AG Osnabrueck, HR B 202460
Executive Directors: Lukas Grunwald, Dr. Jan-Oliver Wagner
___
Openvas-discuss mailing list
Openvas-discuss@wald.intevation.org
https://lists.wald.intevation.org/cgi-bin/mailman/listinfo/openvas-discuss