mirror of
https://github.com/rclone/rclone.git
synced 2024-11-22 16:34:30 +01:00
smb: allow SPN (service principal name) to be configured
This enables connection to clusters. Fixes #6515
This commit is contained in:
parent
5ad942ed87
commit
62a7765e57
@ -37,6 +37,7 @@ func (f *Fs) dial(ctx context.Context, network, addr string) (*conn, error) {
|
|||||||
User: f.opt.User,
|
User: f.opt.User,
|
||||||
Password: pass,
|
Password: pass,
|
||||||
Domain: f.opt.Domain,
|
Domain: f.opt.Domain,
|
||||||
|
TargetSPN: f.opt.SPN,
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -60,6 +60,17 @@ func init() {
|
|||||||
Name: "domain",
|
Name: "domain",
|
||||||
Help: "Domain name for NTLM authentication.",
|
Help: "Domain name for NTLM authentication.",
|
||||||
Default: "WORKGROUP",
|
Default: "WORKGROUP",
|
||||||
|
}, {
|
||||||
|
Name: "spn",
|
||||||
|
Help: `Service principal name.
|
||||||
|
|
||||||
|
Rclone presents this name to the server. Some servers use this as further
|
||||||
|
authentication, and it often needs to be set for clusters. For example:
|
||||||
|
|
||||||
|
cifs/remotehost:1020
|
||||||
|
|
||||||
|
Leave blank if not sure.
|
||||||
|
`,
|
||||||
}, {
|
}, {
|
||||||
Name: "idle_timeout",
|
Name: "idle_timeout",
|
||||||
Default: fs.Duration(60 * time.Second),
|
Default: fs.Duration(60 * time.Second),
|
||||||
@ -109,6 +120,7 @@ type Options struct {
|
|||||||
User string `config:"user"`
|
User string `config:"user"`
|
||||||
Pass string `config:"pass"`
|
Pass string `config:"pass"`
|
||||||
Domain string `config:"domain"`
|
Domain string `config:"domain"`
|
||||||
|
SPN string `config:"spn"`
|
||||||
HideSpecial bool `config:"hide_special_share"`
|
HideSpecial bool `config:"hide_special_share"`
|
||||||
CaseInsensitive bool `config:"case_insensitive"`
|
CaseInsensitive bool `config:"case_insensitive"`
|
||||||
IdleTimeout fs.Duration `config:"idle_timeout"`
|
IdleTimeout fs.Duration `config:"idle_timeout"`
|
||||||
|
Loading…
Reference in New Issue
Block a user