Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Port-Forwarding a server started using native python socket library #40

Open
abhigenie92 opened this issue Mar 30, 2016 · 0 comments
Open

Comments

@abhigenie92
Copy link

Hi, guys! I have been trying to find such a tool since a long time. But I am a bit confused from the docs, please have a look below.

I start a server using the native library:

def register_audio_port(self):
        '''register audio socket and start thread for receiving connections'''
        self.sock_audio = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
        self.sock_audio.setsockopt(socket.SOL_SOCKET, socket.SO_REUSEADDR, 1)
        self.sock_audio.bind(('0.0.0.0',0)) # 0.0.0.0 will allow all connections
        audio_port=self.sock_audio.getsockname()[1]
        self.sock_audio.listen(75)

How can I port-forward using your library on a already started server?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant