Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upGitHub is where the world builds software
Millions of developers and companies build, ship, and maintain their software on GitHub — the largest and most advanced development platform in the world.
Does the "--source-address" works for IPv6? #4696
Comments
|
Yes, the option works with IPv4 and IPv6. Pass in |
|
Here's the output for chiman@ramnode:~/workspace$ youtube-dl -g -Cv https://www.youtube.com/watch?v=Q33SoblaZbU --source-address 2604:180:1::e2b5:5329
[debug] System config: []
[debug] User config: []
[debug] Command-line args: ['-g', '-Cv', 'https://www.youtube.com/watch?v=Q33SoblaZbU', '--source-address', '2604:180:1::e2b5:5329']
[debug] Encodings: locale ANSI_X3.4-1968, fs ANSI_X3.4-1968, out ANSI_X3.4-1968, pref ANSI_X3.4-1968
[debug] youtube-dl version 2015.01.11
[debug] Python version 2.7.3 - Linux-2.6.32-042stab093.5-i686-with-debian-7.7
[debug] exe versions: avconv N-68853-g91bdb24, ffmpeg N-68853-g91bdb24, ffprobe N-68853-g91bdb24, rtmpdump 2.4
[debug] Proxy map: {}
[debug] Public IP address: 2604:180:1::e2b5:5329
https://r11---sn-nx57ynez.googlevideo.com/videoplayback?ms=au&mv=m&source=youtube&fexp=900718%2C922247%2C927622%2C932404%2C934601%2C9406144%2C941004%2C943917%2C945073%2C947209%2C947218%2C947225%2C948124%2C948703%2C950505%2C952302%2C952605%2C952901%2C955301%2C957103%2C957105%2C957201%2C959701&ip=2604%3A180%3A1%3A%3Ae2b5%3A5329&key=yt5&initcwndbps=4773750&gcr=us&id=o-APtY51JOl1BJ_uOLyp8MfjOISqM25hkk-ZEsdOMYhFzv&dur=212.718&upn=5utSTrYelj4&mm=31&mime=video%2Fmp4&mt=1421224141&itag=22&requiressl=yes&sver=3&expire=1421245774&ipbits=0&sparams=dur%2Cgcr%2Cid%2Cinitcwndbps%2Cip%2Cipbits%2Citag%2Cmime%2Cmm%2Cms%2Cmv%2Cratebypass%2Crequiressl%2Csource%2Cupn%2Cexpire&ratebypass=yes&signature=BDFBD82AE0B06C1C1AC1A86AA42E45C58B38A3E9.E35BB0FF4E117CE9C58BADA8071ADC9A164DE877
chiman@ramnode:~/workspace$ youtube-dl -g -Cv https://www.youtube.com/watch?v=Q33SoblaZbU --source-address 2604:180:1::38ae:9b2b
[debug] System config: []
[debug] User config: []
[debug] Command-line args: ['-g', '-Cv', 'https://www.youtube.com/watch?v=Q33SoblaZbU', '--source-address', '2604:180:1::38ae:9b2b']
[debug] Encodings: locale ANSI_X3.4-1968, fs ANSI_X3.4-1968, out ANSI_X3.4-1968, pref ANSI_X3.4-1968
[debug] youtube-dl version 2015.01.11
[debug] Python version 2.7.3 - Linux-2.6.32-042stab093.5-i686-with-debian-7.7
[debug] exe versions: avconv N-68853-g91bdb24, ffmpeg N-68853-g91bdb24, ffprobe N-68853-g91bdb24, rtmpdump 2.4
[debug] Proxy map: {}
[debug] Public IP address: 2604:180:1::e2b5:5329
https://r11---sn-nx57ynez.googlevideo.com/videoplayback?mv=m&fexp=900233%2C900718%2C912820%2C913438%2C927622%2C932404%2C9405148%2C941004%2C943917%2C947209%2C947218%2C947225%2C948124%2C949006%2C952302%2C952605%2C952901%2C955301%2C957103%2C957105%2C957201%2C959701&mt=1421224141&ms=au&id=o-AAK2AtGqWI1KHdCvb9B4zgXstaG7mnqLTz2Yq9GWsHrI&expire=1421245790&key=yt5&sver=3&ip=2604%3A180%3A1%3A%3Ae2b5%3A5329&ipbits=0&ratebypass=yes&source=youtube&mm=31&sparams=dur%2Cgcr%2Cid%2Cinitcwndbps%2Cip%2Cipbits%2Citag%2Cmime%2Cmm%2Cms%2Cmv%2Cratebypass%2Crequiressl%2Csource%2Cupn%2Cexpire&upn=S12RYBNhXsM&itag=22&requiressl=yes&initcwndbps=4773750&gcr=us&mime=video%2Fmp4&dur=212.718&signature=9EB35011F626BF43E95C7DF7A2DEE2B6A601E7FD.6D52AA5C91B53098E0BDCB7D3396A54F3BD8F7A6Both commands shows the same Public IP address, which is: |
|
What output do you get when you run
Can you upload the file
|
|
Here's the output you asked. chiman@ramnode:~/workspace$ curl --interface 2604:180:1::e2b5:5329 yt-dl.org/ip
2604:180:1::e2b5:5329
chiman@ramnode:~/workspace$ curl --interface 2604:180:1::38ae:9b2b yt-dl.org/ip
2604:180:1::38ae:9b2bAnd here's the strace.log |
|
Is that the whole strace log? It looks somewhat cut short. The end should really be along the lines of
|
|
Oh, my mistake, GitHub just truncates it. Here's the full version. |
|
According to the strace log, youtube-dl outputted
so it seems to work just fine. Oh, I apologize, that was the address that did work. I'm gonna need the strace log for
I'm sorry for the needless confusion. |
|
Here's a new one, strace_9b2b.log. |
|
That's quite curious indeed. The final download does work with the correct IP, but the debugging output does not, and does some strange UDP things. I'll investigate. |
|
Great. Should you need more information from my local environment, just say it. Thanks. |
|
Recently, you made the latest commit [ssl] Correct connect creation and there's a link to SERVER_AUTH. I switched the Documentation for 2.7, it says New in version 2.7.9. Previously, I used Python 2.7.3. And just now, I updated to Python 2.7.9, then I try again the And these are the results: chiman@ramnode:~/workspace$ youtube-dl -Cvg https://www.youtube.com/watch?v=Q33SoblaZbU --source-address 2604:180:1::e2b5:5329
[debug] System config: []
[debug] User config: []
[debug] Command-line args: ['-Cvg', 'https://www.youtube.com/watch?v=Q33SoblaZbU', '--source-address', '2604:180:1::e2b5:5329']
[debug] Encodings: locale ANSI_X3.4-1968, fs ANSI_X3.4-1968, out ANSI_X3.4-1968, pref ANSI_X3.4-1968
[debug] youtube-dl version 2015.01.11
[debug] Python version 2.7.9 - Linux-2.6.32-042stab093.5-i686-with-debian-7.8
[debug] exe versions: avconv N-68853-g91bdb24, ffmpeg N-68853-g91bdb24, ffprobe N-68853-g91bdb24, rtmpdump 2.4
[debug] Proxy map: {}
[debug] Public IP address: 2604:180:1::e2b5:5329
https://r11---sn-nx57ynez.googlevideo.com/videoplayback?dur=212.718&ms=au&fexp=900237%2C900718%2C904732%2C907263%2C924627%2C927622%2C941004%2C943917%2C947209%2C947225%2C948124%2C952302%2C952605%2C952901%2C955301%2C957103%2C957105%2C957201%2C958600%2C959701&mt=1421299331&mv=m&mm=31&source=youtube&upn=HAViEyAQssY&id=o-AP-18LYPTOqB65MQh8qU5hWToBSxloUd4qHUoXevFLR5&sparams=cwbhb%2Cdur%2Cgcr%2Cid%2Cinitcwndbps%2Cip%2Cipbits%2Citag%2Cmime%2Cmm%2Cms%2Cmv%2Cpl%2Cratebypass%2Crequiressl%2Csource%2Cupn%2Cexpire&ratebypass=yes&initcwndbps=3331250&cwbhb=yes&ip=2604%3A180%3A1%3A%3Ae2b5%3A5329&requiressl=yes&sver=3&pl=48&gcr=us&expire=1421320957&mime=video%2Fmp4&key=yt5&itag=22&ipbits=0&signature=25B33C8606333C1C48B12CD1DAABCA93325115C1.459FFDE022AD53DF162A8F898E49F34A312632AE
chiman@ramnode:~/workspace$ youtube-dl -Cvg https://www.youtube.com/watch?v=Q33SoblaZbU --source-address 2604:180:1::38ae:9b2b
[debug] System config: []
[debug] User config: []
[debug] Command-line args: ['-Cvg', 'https://www.youtube.com/watch?v=Q33SoblaZbU', '--source-address', '2604:180:1::38ae:9b2b']
[debug] Encodings: locale ANSI_X3.4-1968, fs ANSI_X3.4-1968, out ANSI_X3.4-1968, pref ANSI_X3.4-1968
[debug] youtube-dl version 2015.01.11
[debug] Python version 2.7.9 - Linux-2.6.32-042stab093.5-i686-with-debian-7.8
[debug] exe versions: avconv N-68853-g91bdb24, ffmpeg N-68853-g91bdb24, ffprobe N-68853-g91bdb24, rtmpdump 2.4
[debug] Proxy map: {}
[debug] Public IP address: 2604:180:1::38ae:9b2b
https://r11---sn-nx57ynez.googlevideo.com/videoplayback?ratebypass=yes&mt=1421299331&mv=m&ms=au&gcr=us&source=youtube&itag=22&initcwndbps=3331250&mm=31&sver=3&id=o-AAk64nNr8SKke-DBRUT7FNj66sZGfXxA5OZgiDplXsi7&requiressl=yes&upn=zQFfn970UrM&ipbits=0&expire=1421320973&fexp=900718%2C902543%2C905639%2C907263%2C927622%2C931361%2C940927%2C941004%2C943917%2C947209%2C947225%2C948124%2C952302%2C952605%2C952807%2C952901%2C955301%2C957103%2C957105%2C957201%2C959701&mime=video%2Fmp4&key=yt5&sparams=dur%2Cgcr%2Cid%2Cinitcwndbps%2Cip%2Cipbits%2Citag%2Cmime%2Cmm%2Cms%2Cmv%2Cpl%2Cratebypass%2Crequiressl%2Csource%2Cupn%2Cexpire&ip=2604%3A180%3A1%3A%3A38ae%3A9b2b&pl=48&dur=212.718&signature=B962C79613704120504634739DC77AD34026722F.F3ED5A0961964FC12B0D656069386FCF972513As you can see, now the debugging output is correct.
Problem solved. Thanks. |
|
Thank you very much for the detailed debugging information! I can reproduce the problem with an older Python 2.7 version. I'm therefore reopening this issue - we should fix, work around, or at least warn then. |
|
Fixed in youtube-dl 2015.01.23.2 and newer. See our FAQ if you need help updating. |
Hi,
Does the "--source-address" works for IPv6? I have several IPv6 addresses assigned to my VPS. And I would like to change the outgoing IPv6 that used by youtube-dl.
How can I know if it's working or not?
Thanks.