After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 752705 - rtpbuffer: Add map flag to skip padding
rtpbuffer: Add map flag to skip padding
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gst-plugins-base
unspecified
Other All
: Normal enhancement
: 1.6.1
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks: 756653
 
 
Reported: 2015-07-22 11:06 UTC by Stian Selnes (stianse)
Modified: 2015-10-20 09:11 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
rtpbuffer: Add map flag to skip padding (4.23 KB, patch)
2015-07-22 11:06 UTC, Stian Selnes (stianse)
none Details | Review
rtpbuffer: Add map flag to skip padding (4.23 KB, patch)
2015-10-13 18:34 UTC, Stian Selnes (stianse)
committed Details | Review

Description Stian Selnes (stianse) 2015-07-22 11:06:47 UTC
Encrypted RTP buffers may contain encrypted padding, hence it's
necessary to have an option to relax the validation in order to
successfully map the buffer.

When the flag GST_RTP_BUFFER_MAP_FLAG_SKIP_PADDING is set
gst_rtp_buffer_map() will map the buffer like if padding is not
present.
Comment 1 Stian Selnes (stianse) 2015-07-22 11:06:51 UTC
Created attachment 307901 [details] [review]
rtpbuffer: Add map flag to skip padding
Comment 2 Sebastian Dröge (slomo) 2015-10-11 09:55:45 UTC
Shouldn't it successfully map in any case if the only problem is some padding?
Comment 3 Sebastian Dröge (slomo) 2015-10-11 09:56:30 UTC
Review of attachment 307901 [details] [review]:

::: gst-libs/gst/rtp/gstrtpbuffer.h
@@ +160,3 @@
+ * Additional mapping flags for gst_rtp_buffer_map().
+ *
+ * Since: 1.6

Since: 1.8
Comment 4 Stian Selnes (stianse) 2015-10-13 18:32:36 UTC
Not completely sure what you have in mind? The check of padding is one of the few possible validity checks (RFC3550 A.1) and it's probably not a good idea to always silently ignore this if it fails.

However, the principle of being liberal in what is accepted is usually a good guideline, so maybe it would be a better default to silently ignore padding errors unless asked to explicitly check it (e.g. with a map flag used where padding is of importance). That will of course change the validity check that's been around since 0.10.

For now I'll update the patch with a new docstring.
Comment 5 Stian Selnes (stianse) 2015-10-13 18:34:28 UTC
Created attachment 313212 [details] [review]
rtpbuffer: Add map flag to skip padding

Encrypted RTP buffers may contain encrypted padding, hence it's
necessary to have an option to relax the validation in order to
successfully map the buffer.

When the flag GST_RTP_BUFFER_MAP_FLAG_SKIP_PADDING is set
gst_rtp_buffer_map() will map the buffer like if padding is not
present.
Comment 6 Sebastian Dröge (slomo) 2015-10-15 19:43:04 UTC
Comment on attachment 313212 [details] [review]
rtpbuffer: Add map flag to skip padding

commit 0a668c186626c539d102789e52da55a4c13de35a
Author: Stian Selnes <stian@pexip.com>
Date:   Wed Jul 22 11:31:05 2015 +0200

    rtpbuffer: Add map flag to skip padding
    
    Encrypted RTP buffers may contain encrypted padding, hence it's
    necessary to have an option to relax the validation in order to
    successfully map the buffer.
    
    When the flag GST_RTP_BUFFER_MAP_FLAG_SKIP_PADDING is set
    gst_rtp_buffer_map() will map the buffer like if padding is not
    present.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=752705