[Openvas-discuss] Creating a lot of targets

Juan José Pavlik Salles jjpavlik at gmail.com
Wed Nov 9 02:54:26 CET 2011


I guess i am. I also tried passing the user and password parameters in the
script with -u and -w, but there's no difference, still getting "Failed to
read response."

El 8 de noviembre de 2011 22:27, Brandon Perry
<bperry.volatile at gmail.com>escribió:

> Are you authenticating properly with openvassmd?
>
> 2011/11/8 Juan José Pavlik Salles <jjpavlik at gmail.com>:
> > Hi! it's me again. I tried creating targets with
> >
> > omp -X '<create_target><name>xxx</name><hosts>paste hosts
> > here</hosts></create_target>' -u username -w password
> >
> > and i worked great, but... i have 203 web servers to create... so this is
> > not a good way. I thought about repeating that line in a bash script for
> all
> > my servers, like this:
> >
> > #!/bin/bash
> > TARGETS="/root/pruebas/web_limpio"
> > CONFIG="/root/pruebas/config"
> >
> > if [ ! -e $TARGETS ]; then
> >         echo "$TARGETS doesn't exist"
> >         exit -1
> > fi
> >
> > counter=0
> > for i in `cat $TARGETS`;do
> >         cadena="'<create_target><name>Webserver
> > $counter</name><hosts>$i</hosts></create_target>'"
> >         omp -X $cadena --config-file=$CONFIG
> >         counter=$(($counter+1))
> > done
> >
> > But it does not work, i get "Failed to read response." for every
> webserver.
> > Any clue???
> >
> > --
> > Pavlik Juan José
> >
> > _______________________________________________
> > Openvas-discuss mailing list
> > Openvas-discuss at wald.intevation.org
> > http://lists.wald.intevation.org/mailman/listinfo/openvas-discuss
> >
> >
>
>
>
> --
> http://volatile-minds.blogspot.com -- blog
> http://www.volatileminds.net -- website
>



-- 
Pavlik Juan José
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.wald.intevation.org/pipermail/openvas-discuss/attachments/20111108/9e49de12/attachment.html>


More information about the Openvas-discuss mailing list