OpenSCAP / openscap-daemon

Manages continuous scans of your infrastructure
https://www.open-scap.org/tools/openscap-daemon
GNU Lesser General Public License v2.1
106 stars 32 forks source link

oscapd-cli task-create -i (ERROR EXCEPTION) #91

Closed ridwa closed 8 years ago

ridwa commented 8 years ago

During the creation of new task , i have this result issue :

[root@localhost Bureau]# oscapd-cli task-create -i 
Creating new task in interactive mode
Title: task
Target (empty for localhost): 
Found the following SCAP Security Guide content: 
    1:  /usr/share/xml/scap/ssg/content/ssg-firefox-ds.xml
    2:  /usr/share/xml/scap/ssg/content/ssg-jre-ds.xml
    3:  /usr/share/xml/scap/ssg/content/ssg-rhel6-ds.xml
    4:  /usr/share/xml/scap/ssg/content/ssg-rhel7-ds.xml
Choose SSG content by number (empty for custom content): 3
Tailoring file (absolute path, empty for no tailoring): 
Found the following possible profiles: 
Traceback (most recent call last):
  File "/usr/bin/oscapd-cli", line 787, in <module>
    main()
  File "/usr/bin/oscapd-cli", line 775, in main
    cli_task_create(dbus_iface, args)
  File "/usr/bin/oscapd-cli", line 313, in cli_task_create
    input_file, tailoring_file
  File "/usr/lib/python2.6/site-packages/dbus/proxies.py", line 140, in __call__
    **keywords)
  File "/usr/lib/python2.6/site-packages/dbus/connection.py", line 630, in call_blocking
    message, timeout)
dbus.exceptions.DBusException: org.freedesktop.DBus.Python.AttributeError: Traceback (most recent call last):
  File "/usr/lib/python2.6/site-packages/dbus/service.py", line 702, in _message_cb
    retval = candidate_method(self, *args, **keywords)
  File "/usr/lib/python2.6/site-packages/openscap_daemon/dbus_daemon.py", line 78, in GetProfileChoicesForInput
    input_file, tailoring_file
  File "/usr/lib/python2.6/site-packages/openscap_daemon/system.py", line 86, in get_profile_choices_for_input
    input_file, tailoring_file
  File "/usr/lib/python2.6/site-packages/openscap_daemon/oscap_helpers.py", line 96, in get_profile_choices_for_input
    input_tree, "http://checklists.nist.gov/xccdf/1.1", ret
  File "/usr/lib/python2.6/site-packages/openscap_daemon/oscap_helpers.py", line 82, in scrape_profiles
    for elem in tree.iter("{%s}Profile" % (namespace)):
AttributeError: ElementTree instance has no attribute 'iter'

Could you give some help , thank you

mpreisler commented 8 years ago

Fixed by #92