123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257 |
- .TH TSDECRYPT "1" "December 2011" "tsdecrypt 5.0" "User Commands"
- .SH NAME
- tsdecrypt - Decrypt mpeg transport stream.
- .SH SYNOPSIS
- .B tsdecrypt
- [\fIoptions\fR]
- .SH DESCRIPTION
- tsdecrypt reads incoming mpeg transport stream over UDP/RTP or file and
- then decrypts it using libdvbcsa and keys obtained from OSCAM or similar
- CAMD server. tsdecrypt communicates with CAM server using cs378x (camd35
- over tcp) protocol or newcamd protocol.
- .SH OPTIONS
- .TP
- .SH MAIN OPTIONS
- .PP
- .TP
- \fB\-i\fR, \fB\-\-ident\fR <ident>
- Set ident that will be used when logging to syslog. The prefered format
- for the ident is PROVIDER/CHANNEL.
- .TP
- \fB\-d\fR, \fB\-\-daemon\fR <pidfile>
- When started become a daemon and write pid file to <pidfile>.
- .TP
- \fB\-N\fR, \fB\-\-notify\-program\fR <program>
- Execute \fB<program>\fR when predefined events happen. In order for
- this option to work \fB\-\-ident\fR should also be used.
-
- You can use \fBnotify-script.example\fR file as notification program
- and an example on how to create your own notification script.
-
- See \fBEVENTS\fR section for detailed description of the events.
- .TP
- \fB\-S\fR, \fB\-\-syslog\fR
- Write log messages to local syslog.
- .TP
- \fB\-l\fR, \fB\-\-syslog\-host\fR <addr>
- Set syslog host. tsdecrypt sends messages to this host over tcp in
- syslog compatible format. syslog-ng was tested as receiving syslog server.
- .TP
- \fB\-L\fR, \fB\-\-syslog\-port\fR <port>
- Syslog server port. The default value is \fB514\fR.
- .TP
- \fB\-D\fR, \fB\-\-debug\fR <level>
- Set message debug level. Currently there are five message levels.
- 0 = default messages, 1 = show PSI tables, 2 = show EMMs 3 = show
- duplicate ECMs, 4 = packet debug. 5 = packet debug + mpeg ts packet
- dump.
- Setting higher level enables the levels bellow.
- .TP
- \fB\-j\fR, \fB\-\-pid\-report\fR
- When this option is used, tsdecrypt on exit reports how much packets
- were received on each PID.
- .TP
- \fB\-b\fR, \fB\-\-bench\fR
- Bechmark libdvbcsa decryption. The benchmark is single threaded.
- If you want to fully test your CPU, run couple of tsdecrypts in parallel.
- .TP
- \fB\-V\fR, \fB\-\-version\fR
- Show program version.
- .TP
- \fB\-h\fR, \fB\-\-help\fR
- Show program help.
- .TP
- .SH INPUT OPTIONS
- .PP
- .TP
- \fB\-I\fR, \fB\-\-input\fR <source>
- Where to read from. tsdecrypt supports input from files (-I file.ts or -I -)
- or multicast (-I 224.0.0.1:5000). By default tsdecrypt reads from \fBstdin\fR.
- .TP
- \fB\-R\fR, \fB\-\-input\-rtp\fR
- When reading from multicast assume the input is RTP stream. NOTE: No RTP
- processing/reordering of packets is done. The 12 byte RTP header is just
- stripped out and the stream is then processed as normal mpeg transport
- stream over UDP multicast.
- .TP
- \fB\-z\fR, \fB\-\-input\-ignore\-disc\fR
- Do not report input discontinuity or RTP discontinuity errors.
- .TP
- \fB\-M\fR, \fB\-\-input\-service\fR <service_id>
- Choose the service id. This option must be used when the input is MPTS
- in order to select the correct service (program). If the input is MPTS
- and \fB\-\-input\-service\fR is not used, tsdecrypt chooses the last service
- listed in PAT.
- .TP
- \fB\-W\fR, \fB\-\-input\-dump\fR <filename>
- Save input stream in <filename>. If the input is RTP, the file will contain
- the data without RTP headers (pure mpeg transport stream). Easiest way to
- save the input is using command line like the following:
-
- tsdecrypt -I 239.78.78.78:5000 -O /dev/null -s 0.0.0.0 -W file.ts
- .TP
- .SH OUTPUT OPTIONS
- .PP
- .TP
- \fB\-O\fR, \fB\-\-output\fR <dest>
- Output decrypted stream to <dest>. Destination can be multicast address
- (-O 239.0.0.1:5000) or a file (-O file.ts). The default output is \fBstdout\fR.
- .TP
- \fB\-o\fR, \fB\-\-output\-intf\fR <addr>
- Set multicast output interface.
- .TP
- \fB\-t\fR, \fB\-\-output\-ttl\fR
- Set multicast ttl. The default value is \fB1\fR.
- .TP
- \fB\-g\fR, \fB\-\-output\-tos\fR
- Set TOS value of output packets. The default is not to set any specific TOS.
- .TP
- \fB\-r\fR, \fB\-\-output\-rtp\fR
- Enable RTP output. The default output is standart MPEG TS over UDP, this
- option enables tsdecrypt to output RTP packets.
- .TP
- \fB\-k\fR, \fB\-\-output\-rtp\-ssrc\fR <ssrc>
- Set RTP SSRC field to <ssrc>. By default is is set to \fB0\fR.
- .TP
- \fB\-p\fR, \fB\-\-no\-output\-filter\fR
- Disable output filtering. By default the output filter is enabled and only
- PAT/PMT/SDT and data packets are left in the output. Everything else not
- mentioned in PMT like NIT, EIT, TDT tables and unknown pids is removed.
- .TP
- \fB\-y\fR, \fB\-\-output\-nit\-pass\fR
- Pass throught NIT packets when output filtering is enabled.
- .TP
- \fB\-w\fR, \fB\-\-output\-eit\-pass\fR
- Pass throught EIT (EPG) packets when output filtering is enabled.
- .TP
- \fB\-x\fR, \fB\-\-output\-tdt\-pass\fR
- Pass throught TDT/TOT packets when output filtering is enabled.
- .TP
- .SH CA OPTIONS
- .PP
- .TP
- \fB\-c\fR, \fB\-\-ca\-system\fR <ca_sys>
- Process input EMM/ECM from <ca_sys>. Currently tested and working CA systems
- are \fBCONAX\fR, \fBCRYPTOWORKS\fR, \fBIRDETO\fR, \fBVIACCESS\fR, \fBMEDIAGUARD\fR
- (\fBSECA\fR) and \fBVIDEOGUARD\fR (\fBNDS\fR). Other supported CA systems that
- you can choose but are not tested are \fBNAGRA\fR and \fBDRECRYPT\fR.
- The default <ca_sys> is \fBCONAX\fR.
- .TP
- \fB\-C\fR, \fB\-\-caid\fR <caid>
- Directly set CAID. This is useful if you have couple of CA streams from
- one CA but with different CAIDs.
- .TP
- .SH CAMD OPTIONS
- .PP
- .TP
- \fB\-A\fR, \fB\-\-camd\-proto\fR <protocol>
- Set CAMD server protocol. Valid protocols are \fBCS378X\fR and \fBNEWCAMD\fR.
- If this option is not used the default protocol is \fBCS378X\fR (camd35 over
- tcp).
- .TP
- \fB\-s\fR, \fB\-\-camd\-server\fR <addr[:port]>
- Set CAMD server ip and port (10.0.1.1:2233). Is not set default port
- is \fB2233\fR. 2233 is the default port CS378X protocol, for NEWCAMD
- protocol you probably should choose other port.
- .TP
- \fB\-U\fR, \fB\-\-camd\-user\fR <username>
- Set CAMD user name. The default is \fBuser\fR.
- .TP
- \fB\-P\fR, \fB\-\-camd\-pass\fR <password>
- Set CAMD user password. The default is \fBpass\fR.
- .TP
- \fB\-B\fR, \fB\-\-camd\-des\-key\fR <des_key>
- Set DES key used by NEWCAMD protocol. The default
- is \fB0102030405060708091011121314\fR.
- .TP
- .SH EMM OPTIONS
- .PP
- .TP
- \fB\-e\fR, \fB\-\-emm\fR
- Enable sending EMM's to CAMD for processing. By default EMM processing
- is \fBdisabled\fR and only ECM are processed.
- .TP
- \fB\-Z\fR, \fB\-\-emm\-pid\fR <pid>
- Set EMM pid manually. This option is useful for services that have
- couple of EMM streams from one CA system. Without this option tsdecrypt
- always chooses the first stream from the chosen CA system.
- .TP
- \fB\-E\fR, \fB\-\-emm\-only\fR <hierarchy>
- Disable ECM processing and stream output. This option is useful if the EMM
- stream has very high rate and is interfering with ECM processing. Using
- --emm-only you can run special tsdecrypt dedicated only to card auto update.
- .TP
- \fB\-f\fR, \fB\-\-emm\-report\-time\fR <seconds>
- Set interval for EMM reports. The default is \fB60\fR seconds. Set to \fB0\fR
- to disable EMM reports.
- .TP
- .SH ECM OPTIONS
- .PP
- .TP
- \fB\-X\fR, \fB\-\-ecm\-pid\fR <pid>
- Set ECM pid manually. This option is useful for services that have
- couple of ECM streams from one CA system. Without this option tsdecrypt
- always chooses the first stream from the chosen CA system. Run tsdecrypt
- with --debug 2 and look at CA descriptors in PMT to see what CA streams
- are available.
- .TP
- \fB\-H\fR, \fB\-\-ecm\-report\-time\fR <seconds>
- Set interval for ECM reports. The default is \fB60\fR seconds. Set to \fB0\fR
- to disable ECM reports.
- .TP
- \fB\-G\fR, \fB\-\-ecm\-irdeto\-type\fR <type>
- Set ECM IRDETO type. IRDETO CA send ECMs with different id mixed
- into one stream. Only one of the IDs are valid in given time. This
- option lets you choose which stream to process. The default stream
- type is \fB0\fR.
- .TP
- \fB\-K\fR, \fB\-\-ecm\-no\-log\fR
- Disable logging of ECMs and code words. Code word errors and stats
- reports are not affected by this option.
- .TP
- \fB\-J\fR, \fB\-\-cw\-warn\-time\fR <seconds>
- After how much seconds to warn if valid code word was not received.
- The default is \fB60\fR seconds. Set to \fB0\fR to disable the warning.
- .SH EVENTS
- Notification events are sent when \fB\-\-notify\-program\fR and \fB\-\-ident\fR
- options are used. The event parameters are set as environmental variables
- before executing the external notification program. The variables are:
-
- \fB_TS\fR Unix timestamp of the event.
- \fB_IDENT\fR tsdecrypt ident parameter with "/" replaced by "-".
- \fB_MESSAGE_ID\fR Event message id (for example START, STOP, etc...).
- \fB_MESSAGE_MSG\fR Event message id with "_" replaced by " ".
- \fB_MESSAGE_TEXT\fR Event message text. Human readable event message.
-
- currently defined events are:
-
- \fBSTART\fR tsdecrypt was started.
-
- \fBCODE_WORD_OK\fR Valid code word was received and decryption is
- working ok.
-
- \fBNO_CODE_WORD\fR No valid code word was received for X seconds. The
- decryption process have been suspended until valid
- code word is received.
-
- \fBINPUT_TIMEOUT\fR There was no data on the input.
-
- \fBINPUT_OK\fR The data have appeared on the input.
-
- \fBSTOP\fR tsdecrypt was stopped.
-
- See \fBnotify-script.example\fR for an example on how to create external
- notification program.
- .SH SEE ALSO
- See the README file for more information. If you have questions, remarks,
- problems or you just want to contact the developer, write to:
- \fIgeorgi@unixsol.org\fP
- .TP
- For more info, see the website at
- .I http://georgi.unixsol.org/programs/tsdecrypt/
- .SH AUTHORS
- Written by Georgi Chorbadzhiyski <\fBgeorgi@unixsol.org\fR>
- .SH LICENSE
- This program is free software; you can redistribute it and/or modify it under
- the terms of version 2 of the GNU General Public License as published by the
- Free Software Foundation.
|