set srtp-key to udpsrc caps

Alicia Romero alromor84 at gmail.com
Wed Jul 22 02:30:11 PDT 2015


Thanks for your answer. You were right, but if I use:
const guint8 key[] = { 0, 1, 2, 3, 4, 5, 6, 7, ... };
buf = gst_buffer_new_wrapped (g_memdup (key, sizeof (key)), sizeof(key));

I get:
srtp-key=(buffer)000102030405060708090001020304050607080900010203040506070809

Thanks!!!



2015-07-22 10:25 GMT+02:00 Tim Müller <tim at centricular.com>:

> On Wed, 2015-07-22 at 09:41 +0200, Alicia Romero wrote:
>
> Hi Alicia,
>
> >
> > I use GST_TYPE_BUFFER and the problem is that I think the buffer was
> > not correctly created, because in the log file I can see that it was
> > another key inserted:
> >
> >
> srtp-key=(buffer)303132333435363738393031323334353637383930313233343536373839,
> srtp-cipher=(string)aes-128-icm, srtp-auth=(string)hmac-sha1-80 [...]
> >
> >
> > And the key I am trying to insert is char
> > key[]="0123456789012345678901234567890
> >
> >
> > Why is this happening?
>
> It's inserting what you asked for :)
>
> 30 = 0x30 = hex code for ASCII character '0'.
>
> Perhaps you wanted:
>
> const guint8 key[] = { 0, 1, 2, 3, 4, 5, 6, 7, ... };
>
> buf = gst_buffer_new_wrapped (g_memdup (key, sizeof (key)), sizeof
> (key));
>
> Cheers
>  -Tim
>
> --
> Tim Müller, Centricular Ltd - http://www.centricular.com
>
> _______________________________________________
> gstreamer-devel mailing list
> gstreamer-devel at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/gstreamer-devel/attachments/20150722/27d019c6/attachment.html>


More information about the gstreamer-devel mailing list