Wget, Curl and POST (refs): Difference between revisions

From WikiMLT
No edit summary
 
m (Text replacement - "Network_Security" to "Network_and_Security")
 
(13 intermediate revisions by the same user not shown)
Line 1: Line 1:
* [https://askubuntu.com/q/968652/566421 GET и POST заявки с <code>wget</code> и <code>curl</code>.]
<noinclude>{{ContentArticleHeader/Linux_Server|toc=off}}{{ContentArticleHeader/Network_and_Security}}</noinclude>
* [https://askubuntu.com/a/1031908/566421 Виж също: Auto login on page.]


== WGET ==
Download a script from [https://pastebin.com/raw/HrLTibuR PasteBin] by <code>curl</code>:
== CURL ==
<syntaxhighlight lang="shell" line="1">
* Сваляне на скрипт от '''PasteBin''' с <code>curl</code>:
curl https://pastebin.com/raw/HrLTibuR | \
:<syntaxhighlight lang="bash">
sed -e 's/\r$//' | sudo tee /ust/local/bin/merge-video-sub.sh && \
curl https://pastebin.com/raw/wvV9B1nf | sed -e 's/\r$//' | sudo tee /var/www-security/security-assistant.bash
sudo chmod +x /ust/local/bin/merge-video-sub.sh
sudo chmod +x /var/www-security/security-assistant.bash
</syntaxhighlight>
</syntaxhighlight>
:* [[Remove Carriage Return]]
References:
 
* [https://askubuntu.com/q/968652/566421 GET and POST requests by Wget and/or CURL]
* [https://askubuntu.com/a/1031908/566421 Auto login on page via CLI by the POST command]
* [[Text Processing: Remove Carriage Return]]
<noinclude>
<noinclude>
[[Category:Ubuntu Scripts and Commands|5]]
<div id='devStage'>
{{devStage
| Прндл  = Linux Server
| Прндл1 = Network and Security
| Стадий = 6
| Фаза  = Утвърждаване
| Статус = Утвърден
| ИдтПт  = Spas
| РзбПт  = Spas
| АвтПт  = Spas
| УтвПт  = {{REVISIONUSER}}
| ИдтДт  = 5.08.2022
| РзбДт  = 5.08.2022
| АвтДт  = 5.08.2022
| УтвДт  = {{Today}}
| ИдтРв  = [[Special:Permalink/29951|29951]]
| РзбРв  = [[Special:Permalink/29953|29953]]
| АвтРв  = [[Special:Permalink/29956|29956]]
| УтвРв  = {{REVISIONID}}
}}
</div>
</noinclude>
</noinclude>

Latest revision as of 09:41, 8 September 2022

Down­load a script from Paste­Bin by curl:

curl https://pastebin.com/raw/HrLTibuR | \
sed -e 's/\r$//' | sudo tee /ust/local/bin/merge-video-sub.sh && \
sudo chmod +x /ust/local/bin/merge-video-sub.sh

Ref­er­ences: