Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I am looking for a way to create a scheduled task to automatically download the "DAT Package For Use with McAfee ePO" offered here. The link text on that page ("DAT Package For Use with McAfee ePO") always stays the same, but it points to a different .zip file daily, so the link target differs.

Is there a way to do this?

share|improve this question

2 Answers 2

up vote 2 down vote accepted

Something along these lines (broken into separate lines for readability):

wget --execute=robots=off --recursive --level 1 --span-hosts \
--accept=.zip --no-directories --domains=download.nai.com \
http://www.mcafee.com/apps/downloads/security-updates/security-updates.aspx

If you're always asked to accept before being allowed to download, you'll probably have to save/load cookies. Look at the --[save|load]-cookies option to wget.

share|improve this answer

You might want to try using Selenium, the browser automator. Or, if you're on a Mac, Fake might be an easier solution.

Beyond that, a curl piped to an awk piped back to xargs curl might be your best bet, but that is going to be pretty messy.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.