lighty's life

lighty developer blog

Flv Streaming With Lighttpd

1.4.11 got a new module for streaming Flash movie files called mod_flv_streaming. This module allows you to seek in FLV files using the high performance infrastructure of lighttpd.

The idea is simple and explained and implemented on ‘Streaming’ flv video via PHP, take two at http://www.flashcomguru.com/

But instead of streaming the file through PHP we do it in the webserver. The module expects a request for the URL which matches flv-streaming.extensions and can handle a ‘?start=’ as part of the request.

The information to pass into the ‘start’ parameter is extractly by the flash-player from the meta-data of the flv-files. The meta-data can be setup with flvtool2

Now I leave it to you to combine this with mod_secdownload to create a flv-streaming server for free with deep/hot linking protected movies.

server.modules = ( 
  ...,
  "mod_secdownload", ## optional
  "mod_flv_streaming",
  ...
)
flv-streaming.extensions = ( ".flv" )

Take the flash-player from flashcomguru and adjust the URL in the player and try yourself.

Please note that we won't accept comments for posts older than 3 months! Also please use our bug tracker to report bugs, and our irc channel #lighttpd@libera to chat.

« Patches for 1.4.10 Serving Images From A Database »