"rsync for cloud storage" - Google Drive, S3, Dropbox, Backblaze B2, One Drive, Swift, Hubic, Wasabi, Google Cloud Storage, Azure Blob, Azure Files, Yandex Files
Go azure-blobazure-blob-storageazure-filesbackblaze-b2cloud-storagedropboxencryptionftpfuse-filesystemgogolanggoogle-cloud-storagegoogle-driveonedriveopenstack-swiftrclones3sftpsyncwebdav
ulozto: make password config item be obscured
Nick Craig-Wood679f4fdfa938
diff --git a/backend/ulozto/ulozto.go b/backend/ulozto/ulozto.goindex f1364c6f9..eef719d4f 100644--- a/backend/ulozto/ulozto.go+++ b/backend/ulozto/ulozto.go@@ -22,6 +22,7 @@ import ("github.com/rclone/rclone/fs/config""github.com/rclone/rclone/fs/config/configmap""github.com/rclone/rclone/fs/config/configstruct"+ "github.com/rclone/rclone/fs/config/obscure""github.com/rclone/rclone/fs/fserrors""github.com/rclone/rclone/fs/fshttp""github.com/rclone/rclone/fs/hash"@@ -59,8 +60,8 @@ func init() {{Name: "app_token",Default: "",- Help: "The application token identifying the app. An app API key can be either found in the API " +- "doc https://uloz.to/upload-resumable-api-beta or obtained from customer service.",+ Help: `The application token identifying the app. An app API key can be either found in the API+doc https://uloz.to/upload-resumable-api-beta or obtained from customer service.`,Sensitive: true,},{@@ -70,16 +71,16 @@ func init() {Sensitive: true,},{- Name: "password",- Default: "",- Help: "The password for the user.",- Sensitive: true,+ Name: "password",+ Default: "",+ Help: "The password for the user.",+ IsPassword: true,},{Name: "root_folder_slug",- Help: "If set, rclone will use this folder as the root folder for all operations. For example, " +- "if the slug identifies 'foo/bar/', 'ulozto:baz' is equivalent to 'ulozto:foo/bar/baz' without " +- "any root slug set.",+ Help: `If set, rclone will use this folder as the root folder for all operations. For example,+if the slug identifies 'foo/bar/', 'ulozto:baz' is equivalent to 'ulozto:foo/bar/baz' without+any root slug set.`,Default: "",Advanced: true,Sensitive: true,@@ -237,9 +238,13 @@ func (f *Fs) authenticate(ctx context.Context) (response *api.AuthenticateResponPath: "/v6/session",}+ clearPassword, err := obscure.Reveal(f.opt.Password)+ if err != nil {+ return nil, err+ }authRequest := api.AuthenticateRequest{Login: f.opt.Username,- Password: f.opt.Password,+ Password: clearPassword,}err = f.pacer.Call(func() (bool, error) {diff --git a/docs/content/ulozto.md b/docs/content/ulozto.mdindex cc7bc7d25..e98da5418 100644--- a/docs/content/ulozto.md+++ b/docs/content/ulozto.md@@ -10,7 +10,7 @@ Paths are specified as `remote:path`Paths may be as deep as required, e.g. `remote:directory/subdirectory`.-The initial setup for Box involves filling in the user credentials.+The initial setup for Uloz.to involves filling in the user credentials.`rclone config` walks you through it.## Configuration@@ -49,8 +49,15 @@ username> userOption password.The password for the user.-Enter a value. Press Enter to leave empty.-password> secretPassword+Choose an alternative below. Press Enter for the default (n).+y) Yes, type in my own password+g) Generate random password+n) No, leave this optional password blank (default)+y/g/n> y+Enter the password:+password:+Confirm the password:+password:Edit advanced config?y) Yes@@ -79,8 +86,9 @@ To copy a local folder to a Uloz.to folder called backup:rclone copy /home/source remote:backup### User credentials+The only reliable method is to authenticate the user using-username and password. Uloz.to offers anb API key as well, but+username and password. Uloz.to offers an API key as well, butit's reserved for the use of Uloz.to's in-house applicationand using it in different circumstances is unreliable.@@ -114,7 +122,7 @@ as they can't be used in JSON strings.All files are currently uploaded using a single HTTP request, sofor uploading large files a stable connection is necessary. Rclone willupload up to `--transfers` chunks at the same time (shared among all-uploads).+uploads).### Deleting files@@ -136,7 +144,7 @@ to a specific folder hierarchy.In order to do this you will have to find the `Folder slug` of thefolder you wish to use as root. This will be the last segment-of the URL when you open the relevant folder in the Box web+of the URL when you open the relevant folder in the Uloz.to webinterface.For example, for exploring a folder with URL@@ -154,7 +162,8 @@ Here are the Standard options specific to ulozto (Uloz.to).#### --ulozto-app-token-The application token identifying the app. An app API key can be either found in the API doc https://uloz.to/upload-resumable-api-beta or obtained from customer service.+The application token identifying the app. An app API key can be either found in the API+doc https://uloz.to/upload-resumable-api-beta or obtained from customer service.Properties:@@ -178,6 +187,8 @@ Properties:The password for the user.+**NB** Input to this must be obscured - see [rclone obscure](/commands/rclone_obscure/).+Properties:- Config: password@@ -191,7 +202,9 @@ Here are the Advanced options specific to ulozto (Uloz.to).#### --ulozto-root-folder-slug-If set, rclone will use this folder as the root folder for all operations. For example, if the slug identifies 'foo/bar/', 'ulozto:baz' is equivalent to 'ulozto:foo/bar/baz' without any root slug set.+If set, rclone will use this folder as the root folder for all operations. For example,+if the slug identifies 'foo/bar/', 'ulozto:baz' is equivalent to 'ulozto:foo/bar/baz' without+any root slug set.Properties:@@ -224,6 +237,17 @@ Properties:- Type: Encoding- Default: Slash,BackSlash,Del,Ctl,InvalidUtf8,Dot+#### --ulozto-description++Description of the remote++Properties:++- Config: description+- Env Var: RCLONE_ULOZTO_DESCRIPTION+- Type: string+- Required: false+{{< rem autogenerated options stop >}}## Limitations@@ -245,4 +269,4 @@ exposed in the API. Backends without this capability cannot determinefree space for an rclone mount or use policy `mfs` (most free space)as a member of an rclone union remote.-See [List of backends that do not support rclone about](https://rclone.org/overview/#optional-features) and [rclone about](https://rclone.org/commands/rclone_about/)\ No newline at end of file+See [List of backends that do not support rclone about](https://rclone.org/overview/#optional-features) and [rclone about](https://rclone.org/commands/rclone_about/)