# Authentication For File Download - CMake 3.2.3

**URL:** https://discourse.cmake.org/t/authentication-for-file-download-cmake-3-2-3/5543
**Category:** Usage
**Created:** [April 26, 2022, 11:15am UTC](https://discourse.cmake.org/t/authentication-for-file-download-cmake-3-2-3/5543 "2022-04-26T11:15:30Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![cmacd122](https://discourse.cmake.org/user_avatar/discourse.cmake.org/cmacd122/32/3451_2.png) [@cmacd122](https://discourse.cmake.org/u/cmacd122)
#### Post date: [April 26, 2022, 11:15am UTC](https://discourse.cmake.org/t/authentication-for-file-download-cmake-3-2-3/5543/1 "2022-04-26T11:15:31Z")

</div>

Currently we are using CMake version 3.2.3. We work on a closed/secured network and trying to get new software cleared and installed on the network makes upgrading to a newer version of CMake not possible.  
I say this because I know that CMake 3.2.3 appears to not support “USERPWD” for file download.

I am looking for a solution to authenticate with a repository server such as Artifactory. We download several artifacts from the repo for CMake projects. Soon, however, anonymous authentication will be removed, and I need a way to authenticate using CMake downloading capability.

Is there an HTTP header option in 3.2.3 whereby I can specify the credentials? Are there any other options?

Thanks for any suggestions!

---

<div class="post-metadata">

### Author: ![ben.boeckel](https://discourse.cmake.org/letter_avatar_proxy/v4/letter/b/ea5d25/32.png) [@ben.boeckel](https://discourse.cmake.org/u/ben.boeckel)
#### Post date: [April 26, 2022, 11:21am UTC](https://discourse.cmake.org/t/authentication-for-file-download-cmake-3-2-3/5543/2 "2022-04-26T11:21:31Z")

</div>

I don’t see a built-in way. You could replace any `file(DOWNLOAD)` with `execute_process(COMMAND curl)` (assuming you have `curl` around) to use its powers that way though.

---

<div class="post-metadata">

### Author: ![cmacd122](https://discourse.cmake.org/user_avatar/discourse.cmake.org/cmacd122/32/3451_2.png) [@cmacd122](https://discourse.cmake.org/u/cmacd122)
#### Post date: [April 26, 2022, 12:08pm UTC](https://discourse.cmake.org/t/authentication-for-file-download-cmake-3-2-3/5543/3 "2022-04-26T12:08:45Z")

</div>

Thanks for the suggestion. I am very new to CMake and that helps to push me in the right direction!
