debian/0000755000000000000000000000000012176644220007172 5ustar debian/compat0000644000000000000000000000000211772101160010360 0ustar 9 debian/copyright0000644000000000000000000000603411772101136011123 0ustar Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ Upstream-Name: nicovideo-dl Upstream-Contact: Ying-Chun Liu (PaulLiu) Source: http://sourceforge.jp/projects/nicovideo-dl/ Files: * Copyright: 2009 Keiichiro Nagano 2009 Kimura Youichi 2006-2007 Ricardo Garcia Gonzalez 2008 Ying-Chun Liu (PaulLiu) License: Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: . The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. . THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. . Except as contained in this notice, the name(s) of the above copyright holders shall not be used in advertising or otherwise to promote the sale, use or other dealings in this Software without prior written authorization. Files: debian/* Copyright: 2010 Ying-Chun Liu (PaulLiu) License: Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: . The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. . THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. . Except as contained in this notice, the name(s) of the above copyright holders shall not be used in advertising or otherwise to promote the sale, use or other dealings in this Software without prior written authorization. debian/control0000644000000000000000000000101012176476173010577 0ustar Source: nicovideo-dl Section: web Priority: optional Maintainer: Ying-Chun Liu (PaulLiu) Build-Depends: debhelper (>= 9), python Build-Depends-Indep: docbook-to-man Standards-Version: 3.9.4 Homepage: http://sourceforge.jp/projects/nicovideo-dl/ Package: nicovideo-dl Architecture: all Depends: ${python:Depends}, ${misc:Depends} Description: Download videos from www.nicovideo.jp Small command-line program to download videos from www.nicovideo.jp. Command-line syntax is similar to youtube-dl. debian/watch0000644000000000000000000000020611474074016010221 0ustar version=3 http://sourceforge.jp/projects/nicovideo-dl/releases/ \ .*/projects/nicovideo-dl/downloads/.*/nicovideo-dl-(.*)\.tar\.gz.* debian/patches/0000755000000000000000000000000012176476044010630 5ustar debian/patches/002_sslworkaround.patch0000644000000000000000000000434012176476043015147 0ustar From: Kouichi ONO Description: workaround to connect nicovideo SSLv3 This is a workaround because python urllib2 doesn't connect to some SSLv3 sites. This workaround should be remove when python issue11220 fixed. And please note that we cannot find this bug on Ubuntu. Bug-Debian: http://bugs.debian.org/708642 Bug: http://bugs.python.org/issue11220 Index: nicovideo-dl-0.0.20120212/nicovideo-dl =================================================================== --- nicovideo-dl-0.0.20120212.orig/nicovideo-dl 2013-08-01 16:59:21.000000000 +0800 +++ nicovideo-dl-0.0.20120212/nicovideo-dl 2013-08-01 17:02:52.628557721 +0800 @@ -45,6 +45,28 @@ import codecs import xml.parsers.expat +# custom HTTPS opener, banner's oracle 10g server supports SSLv3 only +import httplib, ssl, urllib2, socket +class HTTPSConnectionV3(httplib.HTTPSConnection): + def __init__(self, *args, **kwargs): + httplib.HTTPSConnection.__init__(self, *args, **kwargs) + + def connect(self): + sock = socket.create_connection((self.host, self.port), self.timeout) + if self._tunnel_host: + self.sock = sock + self._tunnel() + try: + self.sock = ssl.wrap_socket(sock, self.key_file, self.cert_file, ssl_version=ssl.PROTOCOL_SSLv3) + except ssl.SSLError, e: + print("Trying SSLv3.") + self.sock = ssl.wrap_socket(sock, self.key_file, self.cert_file, ssl_version=ssl.PROTOCOL_SSLv23) + +class HTTPSHandlerV3(urllib2.HTTPSHandler): + def https_open(self, req): + return self.do_open(HTTPSConnectionV3, req) + + # Global constants const_version = '2011.02.08' const_project_url = 'http://sourceforge.jp/projects/nicovideo-dl' @@ -397,9 +419,8 @@ account_username = raw_input("Type Niconico E-mail account: ") account_password = getpass.getpass('Type Niconico password and press return: ') -# Install cookie and proxy handlers -urllib2.install_opener(urllib2.build_opener(urllib2.ProxyHandler())) -urllib2.install_opener(urllib2.build_opener(urllib2.HTTPCookieProcessor())) +# Install cookie and custom https handlers +urllib2.install_opener(urllib2.build_opener(urllib2.HTTPCookieProcessor(), HTTPSHandlerV3())) # Log in if account_username is not None: debian/patches/series0000644000000000000000000000006712176421665012047 0ustar 001_replace_magic_number.patch 002_sslworkaround.patch debian/patches/001_replace_magic_number.patch0000644000000000000000000000073011474104227016343 0ustar Subject: Use /usr/bin/python instead of /usr/bin/env python Author: Ying-Chun Liu (PaulLiu) Last-Update: 2010-11-27 Index: nicovideo-dl-0.0.20101127/nicovideo-dl =================================================================== --- nicovideo-dl-0.0.20101127.orig/nicovideo-dl 2010-11-27 11:11:35.000000000 +0800 +++ nicovideo-dl-0.0.20101127/nicovideo-dl 2010-11-27 11:27:26.000000000 +0800 @@ -1,1 +1,1 @@ -#!/usr/bin/env python +#!/usr/bin/python debian/source/0000755000000000000000000000000011474074377010504 5ustar debian/source/format0000644000000000000000000000001411474074377011712 0ustar 3.0 (quilt) debian/nicovideo-dl.sgml0000644000000000000000000001560511772101670012437 0ustar manpage.1'. You may view the manual page with: `docbook-to-man manpage.sgml | nroff -man | less'. A typical entry in a Makefile or Makefile.am is: manpage.1: manpage.sgml docbook-to-man $< > $@ The docbook-to-man binary is found in the docbook-to-man package. Please remember that if you create the nroff version in one of the debian/rules file targets (such as build), you will need to include docbook-to-man in your Build-Depends control field. --> FIRSTNAME"> SURNAME"> Mar 10, 2008"> 1"> grandpaul@gmail.com"> NICOVIDEO-DL"> Debian"> GNU"> GPL"> ]>
&dhemail;
&dhfirstname; &dhsurname; 2003 &dhusername; &dhdate;
&dhucpackage; &dhsection; &dhpackage; download a video file from www.nicovideo.jp &dhpackage; video_url DESCRIPTION This manual page documents briefly the &dhpackage; command. This manual page was written for the &debian; distribution because the original program does not have a manual page. OPTIONS These programs follow the usual &gnu; command line syntax, with long options starting with two dashes (`-'). A summary of options is included below. print this help text and exit account username (e-mail address) account password output video file name activates quiet mode do not download video use title in file name use literal title in file name use .netrc authentication data print final video URL only used with -g, print title too download comment save comment in raw xml output comment file name print program version and exit SEE ALSO youtube-dl (1). AUTHOR This manual page was written by &dhusername; &dhemail; for the &debian; system (but may be used by others). Permission is granted to copy, distribute and/or modify this document under the same terms as the license of the original software.
debian/clean0000644000000000000000000000001711474075046010201 0ustar nicovideo-dl.1 debian/install0000644000000000000000000000002511474074016010560 0ustar nicovideo-dl usr/bin debian/changelog0000644000000000000000000000445112176644220011050 0ustar nicovideo-dl (0.0.20120212-2) unstable; urgency=low * Add debian/patches/002_sslworkaround.patch: workaround for a bug in python urllib2 that makes nicovideo-dl doesn't work at all. (Closes: #708642) - Thanks to Kouichi ONO * Bump Standards-Version to 3.9.4: nothing needs to be changed -- Ying-Chun Liu (PaulLiu) Thu, 01 Aug 2013 23:20:22 +0800 nicovideo-dl (0.0.20120212-1) unstable; urgency=low * New upstream release * Bump Standards-Version to 3.9.3: nothing needs to be changed * Bump debhelper compat to 9 * Update debian/copyright format to v1.0 * Transition to dh_python2 -- Ying-Chun Liu (PaulLiu) Mon, 25 Jun 2012 23:37:34 +0800 nicovideo-dl (0.0.20110724-1) unstable; urgency=low * New upstream release -- Ying-Chun Liu (PaulLiu) Sat, 24 Sep 2011 14:15:24 +0800 nicovideo-dl (0.0.20110208-1) unstable; urgency=low * New upstream release * Bump standard version to 3.9.2: nothing to be changed. -- Ying-Chun Liu (PaulLiu) Tue, 03 May 2011 02:28:37 +0800 nicovideo-dl (0.0.20110122-1) unstable; urgency=low * New upstream release -- Ying-Chun Liu (PaulLiu) Sat, 22 Jan 2011 03:40:11 +0800 nicovideo-dl (0.0.20101127-1) unstable; urgency=low * New upstream release * Use DebSrc 3.0 format. + Remove README.source * Use debhelper 7 * Bump standard version to 3.9.1: nothing to be changed. * Modify copyright to machine readable format. -- Ying-Chun Liu (PaulLiu) Sat, 27 Nov 2010 11:16:30 +0800 nicovideo-dl (0.0.20091209-1) unstable; urgency=low * New upstream release * Bump standard version to 3.8.3: nothing to be changed. * Update debian/copyright for new upstream authors * Add debian/README.source for introducing patch system -- Ying-Chun Liu (PaulLiu) Wed, 09 Dec 2009 17:36:27 +0800 nicovideo-dl (0.0.20080405-1) unstable; urgency=low * New upstream release + Add mp4/swf support + Fix title retrival -- Ying-Chun Liu (PaulLiu) Sun, 20 Apr 2008 23:56:49 +0800 nicovideo-dl (0.0.20080318-1) unstable; urgency=low * Initial release (Closes: #462083) -- Ying-Chun Liu (PaulLiu) Tue, 18 Mar 2008 00:37:17 +0800 debian/rules0000755000000000000000000000037111772102552010251 0ustar #!/usr/bin/make -f # -*- makefile -*- # Uncomment this to turn on verbose mode. #export DH_VERBOSE=1 %: dh $@ --with python2 override_dh_auto_build: nicovideo-dl.1 dh_auto_build nicovideo-dl.1: debian/nicovideo-dl.sgml docbook-to-man $< > $@ debian/manpages0000644000000000000000000000001711474074016010706 0ustar nicovideo-dl.1 debian/dirs0000644000000000000000000000001011474074016010045 0ustar usr/bin