<div dir="ltr"><div style="font-family:arial,sans-serif;font-size:13px">Hello,</div><div style="font-family:arial,sans-serif;font-size:13px"><br></div><div style="font-family:arial,sans-serif;font-size:13px">I have two forward zones defined in config file:</div>
<div style="font-family:arial,sans-serif;font-size:13px"><div>forward-zone:</div><div> name: "<a href="http://somedomain.com/" target="_blank">somedomain.com</a>."</div><div> forward-addr: 8.8.8.8</div>
<div> forward-addr: 8.8.4.4</div><div><br></div><div>forward-zone:</div><div> name: "<a href="http://anotherone.net/" target="_blank">anotherone.net</a>."</div><div> forward-addr: 8.8.8.8</div>
<div> forward-addr: 8.8.4.4</div><div><br></div><div>And when I try to get their names from init function using pythonmod:</div><div> def init(id, cfg):</div><div> cfg.forwards.next()</div><div> print <a href="http://cfg.forwards.name/" target="_blank">cfg.forwards.name</a></div>
<div> return True</div><div><br></div><div>Attribute error is raised ('SwigPyObject' object has no attribute 'name'). Same when I'm trying to access any other attribute defined in struct config_stub (addrs, hosts, isfirst).</div>
<div><br></div><div style>And one more thing... can't access to mod_env global variable since it is set to None.</div><div style> print type(mod_env)</div><div style> <type 'NoneType'></div><div style>
<br></div><div>Using unbound version 1.4.20</div><div>Am I missing something?</div></div></div>