Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Parse URL path to determine file name #2346

Merged
merged 1 commit into from
Dec 9, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion changelog/unreleased/fix-content-disposition.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,5 @@ Bugfix: Fix content disposition header for public links files

https://github.com/cs3org/reva/pull/2303
https://github.com/cs3org/reva/pull/2297
https://github.com/cs3org/reva/pull/2332
https://github.com/cs3org/reva/pull/2332
https://github.com/cs3org/reva/pull/2346
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
---
title: "oidcmapping"
linkTitle: "oidcmapping"
weight: 10
description: >
Configuration for the oidcmapping service
---

# _struct: config_

{{% dir name="insecure" type="bool" default=false %}}
Whether to skip certificate checks when sending requests. [[Ref]](https://github.com/cs3org/reva/tree/master/pkg/auth/manager/oidcmapping/oidcmapping.go#L57)
{{< highlight toml >}}
[auth.manager.oidcmapping]
insecure = false
{{< /highlight >}}
{{% /dir %}}

{{% dir name="issuer" type="string" default="" %}}
The issuer of the OIDC token. [[Ref]](https://github.com/cs3org/reva/tree/master/pkg/auth/manager/oidcmapping/oidcmapping.go#L58)
{{< highlight toml >}}
[auth.manager.oidcmapping]
issuer = ""
{{< /highlight >}}
{{% /dir %}}

{{% dir name="id_claim" type="string" default="sub" %}}
The claim containing the ID of the user. [[Ref]](https://github.com/cs3org/reva/tree/master/pkg/auth/manager/oidcmapping/oidcmapping.go#L59)
{{< highlight toml >}}
[auth.manager.oidcmapping]
id_claim = "sub"
{{< /highlight >}}
{{% /dir %}}

{{% dir name="uid_claim" type="string" default="" %}}
The claim containing the UID of the user. [[Ref]](https://github.com/cs3org/reva/tree/master/pkg/auth/manager/oidcmapping/oidcmapping.go#L60)
{{< highlight toml >}}
[auth.manager.oidcmapping]
uid_claim = ""
{{< /highlight >}}
{{% /dir %}}

{{% dir name="gid_claim" type="string" default="" %}}
The claim containing the GID of the user. [[Ref]](https://github.com/cs3org/reva/tree/master/pkg/auth/manager/oidcmapping/oidcmapping.go#L61)
{{< highlight toml >}}
[auth.manager.oidcmapping]
gid_claim = ""
{{< /highlight >}}
{{% /dir %}}

{{% dir name="userprovidersvc" type="string" default="" %}}
The endpoint at which the GRPC userprovider is exposed. [[Ref]](https://github.com/cs3org/reva/tree/master/pkg/auth/manager/oidcmapping/oidcmapping.go#L62)
{{< highlight toml >}}
[auth.manager.oidcmapping]
userprovidersvc = ""
{{< /highlight >}}
{{% /dir %}}

{{% dir name="usersmapping" type="string" default="" %}}
The OIDC users mapping file path [[Ref]](https://github.com/cs3org/reva/tree/master/pkg/auth/manager/oidcmapping/oidcmapping.go#L63)
{{< highlight toml >}}
[auth.manager.oidcmapping]
usersmapping = ""
{{< /highlight >}}
{{% /dir %}}

2 changes: 1 addition & 1 deletion internal/http/services/owncloud/ocdav/get.go
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ func (s *svc) handleGet(ctx context.Context, w http.ResponseWriter, r *http.Requ

w.Header().Set(HeaderContentType, info.MimeType)
w.Header().Set(HeaderContentDisposistion, "attachment; filename*=UTF-8''"+
path.Base(r.RequestURI)+"; filename=\""+path.Base(r.RequestURI)+"\"")
path.Base(r.URL.Path)+"; filename=\""+path.Base(r.URL.Path)+"\"")
w.Header().Set(HeaderETag, info.Etag)
w.Header().Set(HeaderOCFileID, wrapResourceID(info.Id))
w.Header().Set(HeaderOCETag, info.Etag)
Expand Down