# Does Gitea support authentication via http.extraheader?

**URL:** https://forum.gitea.com/t/does-gitea-support-authentication-via-http-extraheader/7506
**Category:** Install/Maintain/Configure
**Created:** [June 30, 2023, 4:14pm UTC](https://forum.gitea.com/t/does-gitea-support-authentication-via-http-extraheader/7506 "2023-06-30T16:14:35Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![robincodex](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.gitea.com/robincodex/32/3843_2.png) [@robincodex](https://forum.gitea.com/u/robincodex)
#### Post date: [June 30, 2023, 4:14pm UTC](https://forum.gitea.com/t/does-gitea-support-authentication-via-http-extraheader/7506/1 "2023-06-30T16:14:35Z")

</div>

I’m building my golang image and I need to import private repositories in my code, now I can’t import and pull private repositories when I build the image, so is there any way to solve this problem?  
I can’t use SSH because I have disabled it.

---

<div class="post-metadata">

### Author: ![robincodex](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.gitea.com/robincodex/32/3843_2.png) [@robincodex](https://forum.gitea.com/u/robincodex)
#### Post date: [July 5, 2023, 10:34pm UTC](https://forum.gitea.com/t/does-gitea-support-authentication-via-http-extraheader/7506/2 "2023-07-05T22:34:21Z")

</div>

I have resolved it.

```auto
git config --global http.https://yourdomain/.extraheader "AUTHORIZATION: basic $(echo -n "x-access-token:${{ secrets.BOT_TOKEN }}" | base64)"

```
