<feed xmlns='http://www.w3.org/2005/Atom'>
<title>unbound.git/pythonmod/pythonmod.c, branch master</title>
<subtitle>unbound</subtitle>
<id>http://dangofactory.net/cgit/cgit.cgi/Server/unbound.git/atom/pythonmod/pythonmod.c?h=master</id>
<link rel='self' href='http://dangofactory.net/cgit/cgit.cgi/Server/unbound.git/atom/pythonmod/pythonmod.c?h=master'/>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/unbound.git/'/>
<updated>2026-07-23T08:22:02Z</updated>
<entry>
<title>pythonmod: add check return value after ftell() (#1478)</title>
<updated>2026-07-23T08:22:02Z</updated>
<author>
<name>Petr Vaganov</name>
<email>petrvaganoff@gmail.com</email>
</author>
<published>2026-07-23T08:22:02Z</published>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/unbound.git/commit/?id=1bab2dfafa7e7cc6b016b9854a4ff5f1d9af1b50'/>
<id>urn:sha1:1bab2dfafa7e7cc6b016b9854a4ff5f1d9af1b50</id>
<content type='text'>
Variable 'flen', which might receive a negative value at pythonmod.c:493
by calling function 'ftell', is used without checking at pythonmod.c:508
by calling function 'fread'.

Found by the static analyzer Svace (ISP RAS).

Signed-off-by: Petr Vaganov &lt;petrvaganoff@gmail.com&gt;</content>
</entry>
<entry>
<title>- Fix pythonmod script read for numeric overflow.</title>
<updated>2026-06-10T09:24:02Z</updated>
<author>
<name>W.C.A. Wijngaards</name>
<email>wouter@nlnetlabs.nl</email>
</author>
<published>2026-06-10T09:24:02Z</published>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/unbound.git/commit/?id=db1c6d655764efde9987bec7b93bfa3dfc1cb75f'/>
<id>urn:sha1:db1c6d655764efde9987bec7b93bfa3dfc1cb75f</id>
<content type='text'>
</content>
</entry>
<entry>
<title>- For #1352, align with the current Python&lt;3 code.</title>
<updated>2025-09-23T15:31:55Z</updated>
<author>
<name>Yorgos Thessalonikefs</name>
<email>yorgos@nlnetlabs.nl</email>
</author>
<published>2025-09-23T15:31:55Z</published>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/unbound.git/commit/?id=0b7bb751529fe9f5af002ef58db1c51deaf8d77b'/>
<id>urn:sha1:0b7bb751529fe9f5af002ef58db1c51deaf8d77b</id>
<content type='text'>
</content>
</entry>
<entry>
<title>pythonmod: fix HANDLE_LEAK on pythonmod_init</title>
<updated>2025-09-23T14:51:46Z</updated>
<author>
<name>Petr Vaganov</name>
<email>petrvaganoff@gmail.com</email>
</author>
<published>2025-09-23T14:51:46Z</published>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/unbound.git/commit/?id=7c28f1b99cca260523db4d4f7357f854169248fc'/>
<id>urn:sha1:7c28f1b99cca260523db4d4f7357f854169248fc</id>
<content type='text'>
Found by the static analyzer Svace (ISP RAS).

Handle 'script_py' is created at pythonmod.c:436
by calling function 'fopen' and lost at pythonmod.c:457,465.

Signed-off-by: Petr Vaganov &lt;petrvaganoff@gmail.com&gt;
</content>
</entry>
<entry>
<title>ipset-pf-support, move startup and destartup to the front of the module</title>
<updated>2024-07-03T11:53:44Z</updated>
<author>
<name>W.C.A. Wijngaards</name>
<email>wouter@nlnetlabs.nl</email>
</author>
<published>2024-07-03T11:53:44Z</published>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/unbound.git/commit/?id=a335e601e42ea90d0bb9a028734ab45d263efd45'/>
<id>urn:sha1:a335e601e42ea90d0bb9a028734ab45d263efd45</id>
<content type='text'>
func block functions, modstack call deinit function names, and detect
module change when no startup functions are needed.
</content>
</entry>
<entry>
<title>Call module init init again, and new function startup and destartup.</title>
<updated>2024-07-01T14:10:07Z</updated>
<author>
<name>W.C.A. Wijngaards</name>
<email>wouter@nlnetlabs.nl</email>
</author>
<published>2024-07-01T14:10:07Z</published>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/unbound.git/commit/?id=ff653a7ef83e1ed147f21522a21ec9d1dbf6bbf5'/>
<id>urn:sha1:ff653a7ef83e1ed147f21522a21ec9d1dbf6bbf5</id>
<content type='text'>
NULL can be used if the function is not used. Open shared ports during
reload. Deinit is called during reload.
</content>
</entry>
<entry>
<title>ipset-pf-support, fix compilation, close of pf socket.</title>
<updated>2024-07-01T12:54:45Z</updated>
<author>
<name>W.C.A. Wijngaards</name>
<email>wouter@nlnetlabs.nl</email>
</author>
<published>2024-07-01T12:54:45Z</published>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/unbound.git/commit/?id=fd11cd91824bf6d253412aa2a955dbc5792fd04f'/>
<id>urn:sha1:fd11cd91824bf6d253412aa2a955dbc5792fd04f</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Py_NoSiteFlag is not needed since Python 3.8</title>
<updated>2024-04-15T11:52:41Z</updated>
<author>
<name>Petr Mensik</name>
<email>pemensik@redhat.com</email>
</author>
<published>2024-04-15T11:43:58Z</published>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/unbound.git/commit/?id=b11d234f774301c7deac9e76fc7496e4d0ab68d7'/>
<id>urn:sha1:b11d234f774301c7deac9e76fc7496e4d0ab68d7</id>
<content type='text'>
Python since 3.12 prints warning about Py_NoSiteFlag is deprecated. It
seems that variable is not needed since Python 3.8, since it sets in
such cases directly config.site_import variable few moments later.
Move using deprecated variable to versions before that flag in config
could be used only.

This should fix warning like:

pythonmod/pythonmod.c: In function 'pythonmod_init':
pythonmod/pythonmod.c:359:7: warning: 'Py_NoSiteFlag' is deprecated [-Wdeprecated-declarations]
  359 |       Py_NoSiteFlag = 1;
      |       ^~~~~~~~~~~~~
In file included from /usr/include/python3.12/Python.h:48,
                 from pythonmod/pythonmod.c:54:
/usr/include/python3.12/cpython/pydebug.h:14:37: note: declared here
   14 | Py_DEPRECATED(3.12) PyAPI_DATA(int) Py_NoSiteFlag;
      |                                     ^~~~~~~~~~~~~

https://docs.python.org/3/c-api/init.html#c.Py_NoSiteFlag
</content>
</entry>
<entry>
<title>- For multi Python module setups, clean previously parsed module</title>
<updated>2023-10-16T14:03:11Z</updated>
<author>
<name>George Thessalonikefs</name>
<email>yorgos@nlnetlabs.nl</email>
</author>
<published>2023-10-16T14:03:11Z</published>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/unbound.git/commit/?id=e4510c76e54fc50cbcb4b33c2b39f0a51e17684a'/>
<id>urn:sha1:e4510c76e54fc50cbcb4b33c2b39f0a51e17684a</id>
<content type='text'>
  functions in __main__'s dictionary, if any, so that only current
  module functions are registered.
</content>
</entry>
<entry>
<title>- Expose the script filename in the Python module environment 'mod_env'</title>
<updated>2023-10-16T13:47:18Z</updated>
<author>
<name>George Thessalonikefs</name>
<email>yorgos@nlnetlabs.nl</email>
</author>
<published>2023-10-16T13:47:18Z</published>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/unbound.git/commit/?id=63a5280f8f56b71ac73b3df50bf2e393626c0b20'/>
<id>urn:sha1:63a5280f8f56b71ac73b3df50bf2e393626c0b20</id>
<content type='text'>
  instead of the config_file structure which includes the linked list
  of scripts in a multi Python module setup; fixes #79.
</content>
</entry>
</feed>
