hls

package
v1.28.9 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 28, 2022 License: OSL-3.0 Imports: 9 Imported by: 0

README

HLS

CBC

Why does this:

#EXT-X-KEY:METHOD=AES-128,URI="https://cbsios-vh.akamaihd.net/i/temp_hd_galle...

mean CBC?

An encryption method of AES-128 signals that Media Segments are completely encrypted using the Advanced Encryption Standard (AES) [AES_128] with a 128-bit key, Cipher Block Chaining (CBC)

https://datatracker.ietf.org/doc/html/rfc8216#section-4.3.2.4

EXT-X-KEY

If IV is missing, then use KEY for both.

https://github.com/oopsguy/m3u8/blob/master/tool/crypt.go#L25-L39

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Bandwidth added in v1.25.1

type Bandwidth struct {
	*Master
	Target int
}

func (Bandwidth) Less added in v1.25.1

func (b Bandwidth) Less(i, j int) bool

type Decrypter added in v1.23.0

type Decrypter struct {
	cipher.Block
	IV []byte
}

func NewDecrypter added in v1.23.0

func NewDecrypter(src io.Reader) (*Decrypter, error)

func (Decrypter) Copy added in v1.23.8

func (d Decrypter) Copy(dst io.Writer, src io.Reader) (int, error)

type Information added in v1.23.0

type Information struct {
	Duration string
	URI      *url.URL
}

type Key added in v1.24.4

type Key struct {
	Method string
	URI    *url.URL
}

type Master added in v1.23.0

type Master struct {
	Stream []Stream
	Media  []Media
}

func NewMaster added in v1.23.0

func NewMaster(addr *url.URL, body io.Reader) (*Master, error)

func (Master) GetMedia added in v1.24.5

func (m Master) GetMedia(str Stream) *Media

func (Master) Len added in v1.25.1

func (m Master) Len() int

func (Master) Swap added in v1.25.1

func (m Master) Swap(i, j int)

type Media added in v1.23.0

type Media struct {
	GroupID string
	URI     *url.URL
}

type Segment added in v1.23.0

type Segment struct {
	Key  *Key
	Info []Information
}

func NewSegment added in v1.23.0

func NewSegment(addr *url.URL, body io.Reader) (*Segment, error)

func (Segment) Ext added in v1.23.9

func (s Segment) Ext() string

func (Segment) Progress added in v1.24.9

func (s Segment) Progress(i int) (int, string)

type Stream added in v1.23.0

type Stream struct {
	Resolution string
	Bandwidth  int    // handle duplicate resolution
	Codecs     string // handle missing resolution
	Audio      string // link to Media
	URI        *url.URL
}

func (Stream) Format added in v1.25.7

func (s Stream) Format(f fmt.State, verb rune)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL