I am having some difficulty updating a preference through the modify_config
command.

The following log details what I'm doing.

First, I copy an existing config so that I have something fresh to work
with...
DEBUG test_log: Sending: <?xml version="1.0"?>
<create_config>
  <copy>daba56c8-73ec-11df-a475-002264764cea</copy>
  <name>Test_2011-03-22_15:16:19</name>
</create_config>

DEBUG test_log: RECEIVED: <?xml version="1.0"?>
<create_config_response status="201" status_text="OK, resource created"
id="17cc6eb8-a126-4473-87fb-d7c9dbc79625"/>

Then I pull in the details of the configuration I just created.
DEBUG test_log: Sending: <?xml version="1.0"?>
<get_configs sort_field="name" families="1"
config_id="17cc6eb8-a126-4473-87fb-d7c9dbc79625" preferences="1"/>

DEBUG test_log: RECEIVED: <?xml version="1.0"?>
<get_configs_response status="200" status_text="OK">
  <config id="17cc6eb8-a126-4473-87fb-d7c9dbc79625">
    <name>Test_2011-03-22_15:16:19</name>
    <comment/>
    ...
    <preferences>
      ...
      <preference>
        <nvt oid="1.3.6.1.4.1.25623.1.0.801822">
          <name>Nmap NSE: Citrix Enum Servers XML</name>
        </nvt>
        <name>http.pipeline :</name>
        <type>entry</type>
        <value/>
      </preference>
      ...
    </preferences>
  </config>
</get_configs_response>

I issue the modify config command.
DEBUG test_log: Sending: <?xml version="1.0"?>
<modify_config config_id="17cc6eb8-a126-4473-87fb-d7c9dbc79625">
  <preference>
    <nvt oid="1.3.6.1.4.1.25623.1.0.801822"/>
    <name>Nmap NSE: Citrix Enum Servers XML[entry]:http.pipeline :</name>
    <value>NEW VALUE</value>
  </preference>
</modify_config>

DEBUG test_log: RECEIVED: <?xml version="1.0"?>
<modify_config_response status="200" status_text="OK"/>

Then I pull the config again to verify my change.
DEBUG test_log: Sending: <?xml version="1.0"?>
<get_configs sort_field="name" families="1"
config_id="17cc6eb8-a126-4473-87fb-d7c9dbc79625" preferences="1"/>

DEBUG test_log: RECEIVED: <?xml version="1.0"?>
<get_configs_response status="200" status_text="OK">
  <config id="17cc6eb8-a126-4473-87fb-d7c9dbc79625">
    <name>Test_2011-03-22_15:16:19</name>
    <comment/>
    <preferences>
      ...
      <preference>
        <nvt oid="1.3.6.1.4.1.25623.1.0.801822">
          <name>Nmap NSE: Citrix Enum Servers XML</name>
        </nvt>
        <name>http.pipeline :</name>
        <type>entry</type>
        <value></value>
      </preference>
      ...
    </preferences>
  </config>
</get_configs_response>

Even though it says that the configuration took, I do not see my new
preference value in the details...

Any ideas?

Thanks in advance!
Reed
_______________________________________________
Openvas-discuss mailing list
Openvas-discuss@wald.intevation.org
http://lists.wald.intevation.org/mailman/listinfo/openvas-discuss

Reply via email to