Http Auth with rclone

What is the problem you are having with rclone?

I am running into 401/403 errors while trying to copy a remote destination to a local one via SFTP. This has happened only recently and with 5 mirrors, all yield the same results.

2023/10/28 23:39:09 ERROR : : error listing: error listing "": failed to readDir: HTTP Error: 401 Unauthorized
2023/10/28 23:39:09 Failed to lsd with 2 errors: last error was: error listing "": failed to readDir: HTTP Error: 401 Unauthorized```

```curl -u username:password http://xx.xxx.xx.xx:12345/data/LinuxISOs/``` returns this pastebin,

https://pastebin.com/iihb7gaQ

And rclone lsd --http-url http://username:password@xx.xxx.xx.xx:12345/data/ :http:                                                                                          

https://pastebin.com/N9CUq8V8

#### Run the command 'rclone version' and share the full output of the command.

rclone v1.65.0-beta.7462.5c73363b1
- os/version: ubuntu 22.04 (64 bit)
- os/kernel: 6.4.11-x64v3-xanmod1 (x86_64)
- os/type: linux
- os/arch: amd64
- go/version: go1.21.3
- go/linking: static
- go/tags: none

Are you on the latest version of rclone? You can validate by checking the version listed here: https://rclone.org/downloads/
 --> Yes

####  Which cloud storage system are you using? (eg Google Drive)

N/A, http

#### The command you were trying to run (eg `rclone copy /tmp remote:tmp`)  

```rclone lsd iso_server:```
```rclone copy ISOs: iso-hasher: --ignore-case --transfers=20 --checkers=40 -vP --metadata --track-renames --use-mmap --timeout=1m --fast-list --tpslimit=8 --tpslimit-burst=32```
```rclone lsd "type=http,url=http://xx.xxx.xx.xx:12345/data/,user=one\-that\-helps,pass=the\-person\-there"```
```curl -u one-that-helps:the-person-there http://xx.xxx.xx.xx:12345/data/```


#### Please run 'rclone config redacted' and share the full output. If you get command not found, please make sure to update rclone.
<!--  You should use 3 backticks to begin and end your paste to make it readable.   -->

https://pastebin.com/rTBLF3L3


#### A log from the command that you were trying to run with the `-vv` flag  

```rclone lsd iso_server:                                                                                                                                                               ─╯
2023/10/28 23:42:38 ERROR : : error listing: error listing "": failed to readDir: HTTP Error: 401 Unauthorized
2023/10/28 23:42:38 Failed to lsd with 2 errors: last error was: error listing "": failed to readDir: HTTP Error: 401 Unauthorized```

This was working fine up until recently yet I can still reach it via a web browser and tried different locations, so it's not IP related.

Where did you get http_opts, user, pass flags from? It is not something documented in HTTP remote doc...

Change it to:

[iso_server]
type = http
url = http://user:password@xx.xx.xxx.xx:12345

and try rclone lsd iso_server:data again

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.