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

enh: add backend check for download permission for cloud attachements #9592

Merged
merged 1 commit into from
Jun 5, 2024

Conversation

hamza221
Copy link
Contributor

@hamza221 hamza221 commented Apr 22, 2024

For now it silently Fails on draft/outbox save/update

  • Find a way to reflect in the front end for versions prior to 3.6 if needed (not needed)

@hamza221 hamza221 self-assigned this Apr 22, 2024
@hamza221 hamza221 added 2. developing 3. to review enhancement skill:backend Issues and PRs that require backend development skills and removed 2. developing labels Apr 22, 2024
@hamza221 hamza221 marked this pull request as ready for review May 2, 2024 10:41
@hamza221 hamza221 requested a review from ChristophWurst as a code owner May 2, 2024 10:41
@hamza221 hamza221 force-pushed the enh/backend-check-for-download-permission branch from 3985509 to 0b875b4 Compare May 8, 2024 17:09
@hamza221 hamza221 requested review from st3iny and kesselb May 8, 2024 17:09
Copy link
Member

@st3iny st3iny left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The backend side works. When sending the mail a warning is logged, the attachment is still shown in the frontend (composer) but not sent.

I wonder why the frontend let's me pick a file without download permissions. Shouldn't the file picker filter incoming shares without download permissions?

lib/Service/Attachment/AttachmentService.php Outdated Show resolved Hide resolved
@hamza221
Copy link
Contributor Author

hamza221 commented May 13, 2024

they're supposed to be filtered out, it's a regression, I'm investigating
update: 0958ec3

@hamza221 hamza221 force-pushed the enh/backend-check-for-download-permission branch from 0b875b4 to 6648bce Compare May 27, 2024 14:15
@hamza221
Copy link
Contributor Author

hamza221 commented May 28, 2024

I'm still investigating the frontend regression, my doubt i that it's a filepicker regression, since share-attributes are not shown anymore, I'm checking with other colleagues

@st3iny
Copy link
Member

st3iny commented May 28, 2024

I'm still investigating the frontend regression, my doubt i that it's a filepicker regression, since share-attributes are not shown anymore, I'm checking with other colleagues

Sounds good. I'd also say that we can move forward with this PR and look at the frontend separately.

@hamza221
Copy link
Contributor Author

hamza221 commented Jun 3, 2024

@st3iny fyi frontend is fixed here #9697

@hamza221 hamza221 requested review from ChristophWurst and st3iny June 3, 2024 15:24
Copy link
Member

@st3iny st3iny left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested and works

@st3iny st3iny added this to the v3.8.0 milestone Jun 4, 2024
@st3iny
Copy link
Member

st3iny commented Jun 4, 2024

/backport to stable3.7

@st3iny
Copy link
Member

st3iny commented Jun 4, 2024

/backport to stable3.6

Signed-off-by: Hamza Mahjoubi <hamzamahjoubi221@gmail.com>
@hamza221 hamza221 force-pushed the enh/backend-check-for-download-permission branch from 0e71d88 to f0e072e Compare June 5, 2024 14:21
@hamza221 hamza221 enabled auto-merge June 5, 2024 14:21
@st3iny st3iny disabled auto-merge June 5, 2024 15:29
@st3iny st3iny merged commit 8d44f1c into main Jun 5, 2024
34 checks passed
@st3iny st3iny deleted the enh/backend-check-for-download-permission branch June 5, 2024 15:30
@hamza221
Copy link
Contributor Author

hamza221 commented Jun 12, 2024

/backport to 2.9

Update : typo :'(

Copy link

backportbot bot commented Jun 12, 2024

The backport to 2.9 failed. Please do this backport manually.

# Switch to the target branch and update it
git checkout 2.9
git pull origin 2.9

# Create the new backport branch
git checkout -b backport/9592/2.9

# Cherry pick the change from the commit sha1 of the change against the default branch
# This might cause conflicts, resolve them
git cherry-pick f0e072ed

# Push the cherry pick commit to the remote repository and open a pull request
git push origin backport/9592/2.9

Error: Failed to clone repository: Failed to checkout branches: error: pathspec '2.9' did not match any file(s) known to git


Learn more about backports at https://docs.nextcloud.com/server/stable/go.php?to=developer-backports.

@hamza221
Copy link
Contributor Author

/backport to stable2.2

@hamza221
Copy link
Contributor Author

/backport to stable1.15

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
4. to release enhancement skill:backend Issues and PRs that require backend development skills
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants