Python UPnP/IGD Client Implementation?

前端 未结 2 1947
傲寒
傲寒 2021-02-13 22:01

I am searching for an open-source implementation of an UPnP client in Python, and more specifically of its Internet Gateway Device (IGD) part.

For now, I have only been

2条回答
  •  说谎
    说谎 (楼主)
    2021-02-13 22:25

    MiniUPnP source code contains a Python sample code using the C library as an extension module (see testupnpigd.py), which I consider as a proper solution to my problem.

    Rationale: this is not the pure Python solution I was looking for, but:

    • significant effort has already been invested in this library,
    • it is lightweight (it does not address Media Server issues),
    • IGD is typically only used at connection setup, so not integrating it tighter with the Python code does not seem like an issue,
    • as a bonus, it also provides a NAT-PNP implementation (the Apple concurrent of IGD, part of Bonjour).

提交回复
热议问题