Usage examples tls-interaction property for rtspsrc and souphttpsrc

Mandar Joshi emailmandar at gmail.com
Thu Oct 5 02:49:23 UTC 2017


> I usually compile code using this
>
> g++ -g $file.c -o $file `pkg-config gstreamer-1.0 gstreamer-rtsp-1.0
> gstreamer-rtsp-server-1.0 --libs --cflags`
>

Your compile command is fine.

You have to use SurveillanceTlsInteraction like you would use any other GObject.

An excerpt from my code:
----------------------------------------------------------------------------------------------------------------------------------------
#include "surveillance-tls-interaction.h"
...
...
//Create GStreamer elements
//Prepare two GTlsCertficates using one of the functions mentioned
here https://developer.gnome.org/gio/stable/GTlsCertificate.html.
sca->tls_cert is your TLS certificate which the server will validate
and sca->ca_tls_cert is the certificate you use to validate the
server's certificate

    SurveillanceTlsInteraction *interaction =
surveillance_tls_interaction_new (sca->tls_cert, sca->ca_tls_cert);
    g_object_set (rtspclientsink, "tls-interaction", interaction, NULL);

------------------------------------------------------------------------------------------------------------------------------------------

Regards
Mandar Joshi


More information about the gstreamer-devel mailing list