Skip to content

Instantly share code, notes, and snippets.

@legumbre
Created November 17, 2015 00:24
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save legumbre/cb298d57fc5a575ae68f to your computer and use it in GitHub Desktop.
Save legumbre/cb298d57fc5a575ae68f to your computer and use it in GitHub Desktop.
Play tn.com.ar stream with VLC
--
-- VLC SD extension for tn.com.ar
--
-- Server will return 403 (Forbidden) for VLC's User Agent so we fake
-- it by using the iPad UA.
--
-- Place this script under ~/Library/Application Support/org.videolan.vlc/lua/sd/ (Mac OS X)
local iPad_UA = "Mozilla/5.0 (iPad; CPU OS 8_1 like Mac OS X) AppleWebKit/600.1.4 (KHTML, like Gecko) Version/8.0 Mobile/12B410 Safari/600.1.4"
function descriptor()
return { title = "TN vivo iOS Stream" ;
version = "0.1" ;
author = "legumbre" ;
capabilities = {} }
end
function main()
local item = {}
item.path = "http://stream.tn.com.ar/live/smil:tnhd.smil/playlist.m3u8"
item.title= "TN en vivo"
item.genre= "News"
item.options = { "http-user-agent=" .. iPad_UA }
vlc.sd.add_item(item)
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment