Skip to content

int/string in snmp.xml value "Assert error" #571

Description

@hack3rman

Don't attach images of terminals but provide the text.

Describe the bug
According to the documentation you can assign values directly in the template. However I receive an assertion error and the only way is to define the value as variable in the template.

To Reproduce
Steps to reproduce the behavior:
1.

<mib name="IF-MIB">
    <symbol name="ifNumber">
        <value>2</value>
    </symbol>
</mib>
  1. Restart
  2. See error
Traceback (most recent call last):
  File "src/gevent/greenlet.py", line 906, in gevent._gevent_cgreenlet.Greenlet.run
  File "/home/conpot/.local/lib/python3.8/site-packages/conpot/protocols/snmp/snmp_server.py", line 185, in start
    self.xml_mib_config()
  File "/home/conpot/.local/lib/python3.8/site-packages/conpot/protocols/snmp/snmp_server.py", line 110, in xml_mib_config
    value = conpot_core.get_databus().get_value(
  File "/home/conpot/.local/lib/python3.8/site-packages/conpot/core/databus.py", line 43, in get_value
    assert key in self._data
AssertionError
2022-03-15T11:58:52Z <ServiceGreenlet "SNMPServer" at 0x7fca0dec4150: <bound method SNMPServer.start of <conpot.protocols.snmp.snmp_server.SNMPServer object at 0x7fca0deb5550>>('0.0.0.0', 16100)> failed with AssertionError

Expected behavior
int and strings should be interpreted directly in the module template.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions