Power

 View Only
Expand all | Collapse all

Curl and wget restricted in our environment

  • 1.  Curl and wget restricted in our environment

    Posted Mon August 19, 2024 03:55 AM

    Hi Team,

       Our environment curl and wget is restricted it's there any other command equivalent in AIX server could you please guide us it will help for the same.



    ------------------------------
    Karur Vysya Limited
    ------------------------------


  • 2.  RE: Curl and wget restricted in our environment

    Posted Tue August 20, 2024 03:59 PM

    It really depends on what you are using the commands for.  I normally use wget to download files from the Internet.

    When unavailable, perl has some functionality which you might be able to use.
    Using wget:

    wget <URL>

    Using perl:

    perl -MLWP::Simple -e 'getprint "<URL>"' > /tmp/myfile.foo
    
    # for example:
    
    perl -MLWP::Simple -e 'getprint "https://www.yahoo.com"' > /tmp/home.yahoo.html

    There is only one caveat.

    While wget creates a file with the same name as the original URL, when you use perl you will have to redirect the output from the perl command to a file.



    ------------------------------
    Abraham Alvarez
    ------------------------------