Wget на Windows 10 через экран входа
Я пытаюсь использовать wget для загрузки файлов с веб-сайта, доступ к которому осуществляется через страницу входа. Это команда, которую я пробовал:
wget --save-cookies cookies.txt --keep-session-cookies --post-data "ctl00_PlaceHolderMain_signInControl_UserName = brassj & ctl00_PlaceHolderMain_signInControl_Password = combo123" --delete-after " https://dataroom.org/org/org/org/org_org.org/azat.org/azat.org/org/org.org/azat. SignInPage / Pages / SignInPage.aspx "
wget --load-cookies cookies.txt " https://dataroom.indianatollroad.org/sites/PUSH/PUSHII/Shared%20Documents/Forms/AllItems/.aspx "
Резюме моих результатов:
- Подключается к странице входа и сохраняет SignInPage.aspx.tmp
- Удаляет SigninPage.aspx.tmp
- "Решение wget (wget) ... не выполнено: такой хост не известен."
- "wget: невозможно определить адрес хоста" wget ""
- "Повторное использование существующего подключения к dataroom.indianatollroad.org:443."
- «HTTP-запрос отправлен, ожидание ответа ... 404 Not Found»
- "Ошибка 404 не найдено."
Я не уверен, что я делаю неправильно, чтобы получить этот ответ. Кто-нибудь с большим знанием / опытом, я - полный новичок, видят, в какой момент / пункты я делаю оплошности?
Любая помощь будет оценена.
Спасибо Брайан
РЕДАКТИРОВАТЬ: Добавлено "&&" между двумя командами в направлении от @darnir. Это полный вывод:
H:\>wget --save-cookies cookies.txt --keep-session-cookies \ --post-data "ctl00_PlaceHolderMain_signInControl_UserName=brassj&ctl00_PlaceHolderMain_signInControl_Password=combo" \ --delete-after "https://dataroom.indianatollroad.org/_layouts/15/zavaz.SignInPage/Pages/SignInPage.aspx" && \ wget --load-cookies cookies.txt \ "https://dataroom.indianatollroad.org/sites/PUSH/PUSHII/Shared%20Documents/Forms/AllItems/.aspx" --2018-11-14 08:15:15-- https://dataroom.indianatollroad.org/_layouts/15/zavaz.SignInPage/Pages/SignInPage.aspx Resolving dataroom.indianatollroad.org (dataroom.indianatollroad.org)... 12.2.86.251 Connecting to dataroom.indianatollroad.org (dataroom.indianatollroad.org)|12.2.86.251|:443... connected. HTTP request sent, awaiting response... 200 OK Length: 9186 (9.0K) [text/html] Saving to: 'SignInPage.aspx.tmp' SignInPage.aspx.tmp 100%[=================================================>] 8.97K --.-KB/s in 0.05s 2018-11-14 08:15:26 (188 KB/s) - 'SignInPage.aspx.tmp' saved [9186/9186] Removing SignInPage.aspx.tmp. --2018-11-14 08:15:27-- https://dataroom.indianatollroad.org/sites/PUSH/PUSHII/Shared%20Documents/Forms/AllItems/.aspx Resolving dataroom.indianatollroad.org (dataroom.indianatollroad.org)... 12.2.86.251 Connecting to dataroom.indianatollroad.org (dataroom.indianatollroad.org)|12.2.86.251|:443... connected. HTTP request sent, awaiting response... 404 Not Found 2018-11-14 08:15:27 ERROR 404: Not Found.
Я зациклен на этом, но когда я получаю доступ к этим страницам через браузеры, они ведут себя по-разному. И в Chrome, и в Firefox, если я добавлю URL для текущей страницы документа, браузеры откроют их без проблем (информация для входа в систему сохранена). Однако, если я добавлю URL-адрес для страницы входа и введу информацию для входа, меня направят на https://dataroom.indianatollroad.org/_layouts/15/AccessDenied.aspx?Source=https%3A%2F%2Fdataroom % 2Eindianatollroad% 2Eorg "и знаю, что я использую правильное имя пользователя и пароль, потому что, если они введены неправильно, они всплывают на странице входа и не могут продолжить.
Еще раз спасибо за любую помощь, которую вы можете предоставить.
РЕДАКТИРОВАТЬ РЕДАКЦИЯ, ПОЛУЧЕННАЯ ОТ ОБНОВЛЕННОЙ КОМАНДЫ
C:\WINDOWS\system32>wget --save-cookies cookies.txt --keep-session- cookies --post-data "ctl00_PlaceHolderMain_signInControl_UserName=brassj&ctl00_PlaceHolderMain_signInControl_Password=combo123" --delete-after "https://dataroom.indianatollroad.org/_layouts/15/zavaz.SignInPage/Pages/SignInPage.aspx" && wget -e robots=off --no-parent -l0 --ignore-case -x -nH -r -v -N -nd -A pdf -d --no-check-certificate --auth-no-challenge --load-cookies cookies.txt -U Mozilla.com "https://dataroom.indianatollroad.org/sites/PUSH/PUSHII/Shared Documents/Forms/AllItems.aspx" --2018-11-15 08:52:52-- https://dataroom.indianatollroad.org/_layouts/15/zavaz.SignInPage/Pages/SignInPage.aspx Resolving dataroom.indianatollroad.org (dataroom.indianatollroad.org)... 12.2.86.251 Connecting to dataroom.indianatollroad.org (dataroom.indianatollroad.org)|12.2.86.251|:443... connected. HTTP request sent, awaiting response... 200 OK Length: 9186 (9.0K) [text/html] Saving to: 'SignInPage.aspx.tmp' SignInPage.aspx.tmp 100%[========================================================================================================================================>] 8.97K --.-KB/s in 0.005s 2018-11-15 08:52:53 (1.69 MB/s) - 'SignInPage.aspx.tmp' saved [9186/9186] Removing SignInPage.aspx.tmp. Setting --check-certificate (checkcertificate) to 0 Setting --check-certificate (checkcertificate) to 0 Setting --auth-no-challenge (authnochallenge) to 1 Setting --auth-no-challenge (authnochallenge) to 1 Setting --load-cookies (loadcookies) to cookies.txt Setting --load-cookies (loadcookies) to cookies.txt Setting --user-agent (useragent) to Mozilla.com Setting --user-agent (useragent) to Mozilla.com DEBUG output created by Wget 1.19.4 on mingw32. Reading HSTS entries from DEBUG output created by Wget 1.19.4 on mingw32. xt 7am Files (x86)\GnuWin32\bin/wget.ini/.wget-hsts URI encoding = 'CP1252' converted 'https://dataroom.indianatollroad.org/sites/PUSH/PUSHII/Shared Documents/Forms/AllItems.aspx' (CP1252) -> 'https://dataroom.indianatollroad.org/sites/PUSH/PUSHII/Shared Documents/Forms/AllItems.aspx' (UTF-8) URI encoding = 'CP1252' Enqueuing https://dataroom.indianatollroad.org/sites/PUSH/PUSHII/Shared%20Documents/Forms/AllItems.aspx at depth 0 Queue count 1, maxcount 1. [IRI Enqueuing 'https://dataroom.indianatollroad.org/sites/PUSH/PUSHII/Shared%20Documents/Forms/AllItems.aspx' with 'CP1252' Dequeuing https://dataroom.indianatollroad.org/sites/PUSH/PUSHII/Shared%20Documents/Forms/AllItems.aspx at depth 0 Queue count 0, maxcount 1. converted 'https://dataroom.indianatollroad.org/sites/PUSH/PUSHII/Shared%20Documents/Forms/AllItems.aspx' (CP1252) -> 'https://dataroom.indianatollroad.org/sites/PUSH/PUSHII/Shared Documents/Forms/AllItems.aspx' (UTF-8) Converted file name 'AllItems.aspx' (UTF-8) -> 'AllItems.aspx' (CP1252) --2018-11-15 08:52:53-- https://dataroom.indianatollroad.org/sites/PUSH/PUSHII/Shared%20Documents/Forms/AllItems.aspx Resolving dataroom.indianatollroad.org (dataroom.indianatollroad.org)... seconds 0.00, 12.2.86.251 Caching dataroom.indianatollroad.org => 12.2.86.251 Connecting to dataroom.indianatollroad.org (dataroom.indianatollroad.org)|12.2.86.251|:443... seconds 0.00, connected. Created socket 3. Releasing 0x0127af80 (new refcount 1). Initiating SSL handshake. seconds 900.00, Winsock error: 0 Handshake successful; connected socket 3 to SSL handle 0x0127dd98 certificate: subject: CN=*.indianatollroad.org,OU=Domain Control Validated issuer: CN=Go Daddy Secure Certificate Authority - G2,OU=http://certs.godaddy.com/repository/,O=GoDaddy.com\\, Inc.,L=Scottsdale,ST=Arizona,C=US X509 certificate successfully verified and matches host dataroom.indianatollroad.org ---request begin--- GET /sites/PUSH/PUSHII/Shared%20Documents/Forms/AllItems.aspx HTTP/1.1 User-Agent: Mozilla.com Accept: */* Accept-Encoding: identity Host: dataroom.indianatollroad.org Connection: Keep-Alive ---request end--- HTTP request sent, awaiting response... seconds 900.00, Winsock error: 0 seconds 900.00, Winsock error: 0 ---response begin--- HTTP/1.1 302 Found Content-Type: text/html; charset=utf-8 Location: https://dataroom.indianatollroad.org/sites/PUSH/PUSHII/_layouts/15/Authenticate.aspx?Source=%2Fsites%2FPUSH%2FPUSHII%2FShared%20Documents%2FForms%2FAllItems%2Easpx Server: Microsoft-IIS/8.5 X-SharePointHealthScore: 0 SPRequestGuid: a0a0a29e-411b-d0c3-23fd-e5c2762063ee request-id: a0a0a29e-411b-d0c3-23fd-e5c2762063ee X-FRAME-OPTIONS: SAMEORIGIN SPRequestDuration: 14 SPIisLatency: 1 X-Powered-By: ASP.NET MicrosoftSharePointTeamServices: 15.0.0.4841 X-Content-Type-Options: nosniff X-MS-InvokeApp: 1; RequireReadOnly Date: Thu, 15 Nov 2018 14:53:48 GMT Content-Length: 280 ---response end--- 302 Found Registered socket 3 for persistent reuse. URI content encoding = 'utf-8' Location: https://dataroom.indianatollroad.org/sites/PUSH/PUSHII/_layouts/15/Authenticate.aspx?Source=%2Fsites%2FPUSH%2FPUSHII%2FShared%20Documents%2FForms%2FAllItems%2Easpx [following] Skipping 280 bytes of body: [seconds 900.00, Winsock error: 0 <html><head><title>Object moved</title></head><body> <h2>Object moved to <a href="https://dataroom.indianatollroad.org/sites/PUSH/PUSHII/_layouts/15/Authenticate.aspx?Source=%2Fsites%2FPUSH%2FPUSHII%2FShared%20Documents%2FForms%2FAllItems%2Easpx">here</a>.</h2> </body></html> ] done. URI content encoding = None converted 'https://dataroom.indianatollroad.org/sites/PUSH/PUSHII/_layouts/15/Authenticate.aspx?Source=%2Fsites%2FPUSH%2FPUSHII%2FShared%20Documents%2FForms%2FAllItems%2Easpx' (CP1252) -> 'https://dataroom.indianatollroad.org/sites/PUSH/PUSHII/_layouts/15/Authenticate.aspx?Source=%2Fsites%2FPUSH%2FPUSHII%2FShared Documents%2FForms%2FAllItems.aspx' (UTF-8) Converted file name 'AllItems.aspx' (UTF-8) -> 'AllItems.aspx' (CP1252) --2018-11-15 08:52:53-- https://dataroom.indianatollroad.org/sites/PUSH/PUSHII/_layouts/15/Authenticate.aspx?Source=%2Fsites%2FPUSH%2FPUSHII%2FShared%20Documents%2FForms%2FAllItems.aspx Reusing existing connection to dataroom.indianatollroad.org:443. Reusing fd 3. ---request begin--- GET /sites/PUSH/PUSHII/_layouts/15/Authenticate.aspx?Source=%2Fsites%2FPUSH%2FPUSHII%2FShared%20Documents%2FForms%2FAllItems.aspx HTTP/1.1 User-Agent: Mozilla.com Accept: */* Accept-Encoding: identity Host: dataroom.indianatollroad.org Connection: Keep-Alive ---request end--- HTTP request sent, awaiting response... seconds 900.00, Winsock error: 0 seconds 900.00, Winsock error: 0 ---response begin--- HTTP/1.1 302 Found Cache-Control: private Content-Type: text/html; charset=utf-8 Location: /_layouts/15/zavaz.SignInPage/Pages/SignInPage.aspx?ReturnUrl=%2fsites%2fPUSH%2fPUSHII%2f_layouts%2f15%2fAuthenticate.aspx%3fSource%3d%252Fsites%252FPUSH%252FPUSHII%252FShared%2520Documents%252FForms%252FAllItems.aspx&Source=%2Fsites%2FPUSH%2FPUSHII%2FShared%20Documents%2FForms%2FAllItems.aspx Server: Microsoft-IIS/8.5 X-SharePointHealthScore: 0 X-AspNet-Version: 4.0.30319 SPRequestGuid: a0a0a29e-f127-d0c3-23fd-efad2de89403 request-id: a0a0a29e-f127-d0c3-23fd-efad2de89403 X-FRAME-OPTIONS: SAMEORIGIN SPRequestDuration: 7 SPIisLatency: 1 X-Powered-By: ASP.NET MicrosoftSharePointTeamServices: 15.0.0.4841 X-Content-Type-Options: nosniff X-MS-InvokeApp: 1; RequireReadOnly Date: Thu, 15 Nov 2018 14:53:48 GMT Content-Length: 415 ---response end--- 302 Found URI content encoding = 'utf-8' Location: /_layouts/15/zavaz.SignInPage/Pages/SignInPage.aspx?ReturnUrl=%2fsites%2fPUSH%2fPUSHII%2f_layouts%2f15%2fAuthenticate.aspx%3fSource%3d%252Fsites%252FPUSH%252FPUSHII%252FShared%2520Documents%252FForms%252FAllItems.aspx&Source=%2Fsites%2FPUSH%2FPUSHII%2FShared%20Documents%2FForms%2FAllItems.aspx [following] Skipping 415 bytes of body: [seconds 900.00, Winsock error: 0 <html><head><title>Object moved</title></head><body> <h2>Object moved to <a href="/_layouts/15/zavaz.SignInPage/Pages/SignInPage.aspx?ReturnUrl=%2fsites%2fPUSH%2fPUSHII%2f_layouts%2f15%2fAuthenticate.aspx%3fSource%3d%252Fsites%252FPUSH%252FPUSHII%252FShared%2520Documents%252FForms%252FAllItems.aspx&Source=%2Fsites%2FPUSH%2FPUSHII%2FShared%20Documents%2FForms%2FAllItems.aspx">here</a>.</h2> </body></html> ] done. URI content encoding = None converted 'https://dataroom.indianatollroad.org/_layouts/15/zavaz.SignInPage/Pages/SignInPage.aspx?ReturnUrl=%2fsites%2fPUSH%2fPUSHII%2f_layouts%2f15%2fAuthenticate.aspx%3fSource%3d%252Fsites%252FPUSH%252FPUSHII%252FShared%2520Documents%252FForms%252FAllItems.aspx&Source=%2Fsites%2FPUSH%2FPUSHII%2FShared%20Documents%2FForms%2FAllItems.aspx' (CP1252) -> 'https://dataroom.indianatollroad.org/_layouts/15/zavaz.SignInPage/Pages/SignInPage.aspx?ReturnUrl=%2fsites%2fPUSH%2fPUSHII%2f_layouts%2f15%2fAuthenticate.aspx%3fSource%3d%2Fsites%2FPUSH%2FPUSHII%2FShared%20Documents%2FForms%2FAllItems.aspx&Source=%2Fsites%2FPUSH%2FPUSHII%2FShared Documents%2FForms%2FAllItems.aspx' (UTF-8) Converted file name 'AllItems.aspx' (UTF-8) -> 'AllItems.aspx' (CP1252) --2018-11-15 08:52:54-- https://dataroom.indianatollroad.org/_layouts/15/zavaz.SignInPage/Pages/SignInPage.aspx?ReturnUrl=%2fsites%2fPUSH%2fPUSHII%2f_layouts%2f15%2fAuthenticate.aspx%3fSource%3d%2Fsites%2FPUSH%2FPUSHII%2FShared%20Documents%2FForms%2FAllItems.aspx&Source=%2Fsites%2FPUSH%2FPUSHII%2FShared%20Documents%2FForms%2FAllItems.aspx Reusing existing connection to dataroom.indianatollroad.org:443. Reusing fd 3. ---request begin--- GET /_layouts/15/zavaz.SignInPage/Pages/SignInPage.aspx?ReturnUrl=%2fsites%2fPUSH%2fPUSHII%2f_layouts%2f15%2fAuthenticate.aspx%3fSource%3d%2Fsites%2FPUSH%2FPUSHII%2FShared%20Documents%2FForms%2FAllItems.aspx&Source=%2Fsites%2FPUSH%2FPUSHII%2FShared%20Documents%2FForms%2FAllItems.aspx HTTP/1.1 User-Agent: Mozilla.com Accept: */* Accept-Encoding: identity Host: dataroom.indianatollroad.org Connection: Keep-Alive ---request end--- HTTP request sent, awaiting response... seconds 900.00, Winsock error: 0 seconds 900.00, Winsock error: 0 ---response begin--- HTTP/1.1 200 OK Cache-Control: private, no-store Content-Type: text/html; charset=utf-8 Server: Microsoft-IIS/8.5 X-SharePointHealthScore: 0 X-AspNet-Version: 4.0.30319 SPRequestGuid: a0a0a29e-9138-d0c3-23fd-e4f5b31ab2dc request-id: a0a0a29e-9138-d0c3-23fd-e4f5b31ab2dc X-FRAME-OPTIONS: SAMEORIGIN SPRequestDuration: 15 SPIisLatency: 0 X-Powered-By: ASP.NET MicrosoftSharePointTeamServices: 15.0.0.4841 X-Content-Type-Options: nosniff X-MS-InvokeApp: 1; RequireReadOnly Date: Thu, 15 Nov 2018 14:53:48 GMT Content-Length: 14576 ---response end--- 200 OK URI content encoding = 'utf-8' Length: 14576 (14K) [text/html] Saving to: 'AllItems.aspx.tmp' AllItems.aspx.tmp 0%[ ] 0 --.-KB/s seconds 900.00, Winsock error: 0 seconds 900.00, Winsock error: 0 AllItems.aspx.tmp 100%[========================================================================================================================================>] 14.23K --.-KB/s in 0.01s Last-modified header missing -- time-stamps turned off. 2018-11-15 08:52:54 (1.28 MB/s) - 'AllItems.aspx.tmp' saved [14576/14576] Deciding whether to enqueue "https://dataroom.indianatollroad.org/_layouts/15/zavaz.SignInPage/Pages/SignInPage.aspx?ReturnUrl=%2fsites%2fPUSH%2fPUSHII%2f_layouts%2f15%2fAuthenticate.aspx%3fSource%3d%2Fsites%2FPUSH%2FPUSHII%2FShared%20Documents%2FForms%2FAllItems.aspx&Source=%2Fsites%2FPUSH%2FPUSHII%2FShared%20Documents%2FForms%2FAllItems.aspx". Going to "_layouts/15/zavaz.SignInPage/Pages" would escape "sites/PUSH/PUSHII/Shared Documents/Forms" with no_parent on. Decided NOT to load it. Redirection "https://dataroom.indianatollroad.org/_layout/15/zavaz.SignInPage/Pages/SignInPage.aspx?ReturnUrl=%2fsites%2fPUSH%2fPUSHII%2f_layouts%2f15%2fAuthenticate.aspx%3fSource%3d%2Fsites%2FPUSH%2FPUSHII%2FShared%20Documents%2FForms%2FAllItems.aspx&Source=%2Fsites%2FPUSH%2FPUSHII%2FShared%20Documents%2FForms%2FAllItems.aspx" failed the test. Removing file due to recursive rejection criteria in recursive_retrieve(): Removing AllItems.aspx.tmp since it should be rejected. FINISHED --2018-11-15 08:52:54-- Total wall clock time: 1.1s Downloaded: 1 files, 14K in 0.01s (1.28 MB/s)
0 ответов на вопрос
Похожие вопросы
-
4
Использование публичных терминалов для входа в ваши личные учетные данные
-
2
Звоните, но не загружайте страницу с помощью wget
-
1
Войдите в группу новостей с thunderbird3.0B2 для группы новостей, которая не требует входа
-
-
1
wget и cookies.txt - domain.tld против .domain.tld
-
2
Как отключить функцию «непрочитанные сообщения» на экране входа в Windows XP?
-
5
Как быстро очистить куки для определенного сайта с помощью Safari для Mac?
-
6
Автоматически запускать скрипт при входе в Windows
-
4
Windows XP заблокирована, нужно вернуться обратно
-
1
Каковы решения проблемы Ha.ckers.org?
-
4
Вход в Windows XP без клавиатуры