A
A
Atilla2016-10-11 22:23:21
Python
Atilla, 2016-10-11 22:23:21

How to securely transfer data between two computers through NAT?

There is a task: you need to transfer a video stream over RTP using gstreamer and transfer raw data over TCP from one computer sitting behind NAT / firewall to another computer sitting behind NAT / firewall. There is an external server with a white address. And it would be nice not to load this server unnecessarily.
Question: what is the best way to solve this problem?
It will be good if it is a python library for the server and clients.

Answer the question

In order to leave comments, you need to log in

4 answer(s)
A
Andrew, 2016-10-12
@Atilla

You need the STUN protocol - it uses an external server only to establish a connection, and then the exchange goes point-to-point. You can look for its ready-made implementations, or develop something yourself in its likeness.

A
Alexey Cheremisin, 2016-10-12
@leahch

Есть gstreamer-rtsp-server, библиотека для gstreamer. В ней, если взять исходники, есть пример для rtsp/rtp proxy. На его основе можно сделать свой прокси, который будет жить на белом сервере.
https://github.com/GStreamer/gst-rtsp-server/tree/...

S
silverjoe, 2016-10-13
@silverjoe

> Вопрос: как решить эту проблему надежнее всего?
OpenVPN с шифрованием.

L
Leonid, 2020-09-17
@sled

1. Получить внешний IP адрес и порт для ПК1 и ПК2
2. Через общий аккаунт соцсети (ВК) обменяться IP адресами и портами

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question