Bug: cannot upload .zip file in issue on Gitea.com on Windows10 #6221

Closed
opened 2025-11-02 06:48:52 -06:00 by GiteaMirror · 7 comments
Owner

Originally created by @gymgym1212 on GitHub (Oct 27, 2020).

  • Gitea version (or commit ref):the version of Gitea.com - go1.15.3
  • Operating system: failed on windows but succeeded on macOS
  • Can you reproduce the bug at https://gitea.com:
    • Yes
Originally created by @gymgym1212 on GitHub (Oct 27, 2020). <!-- NOTE: If your issue is a security concern, please send an email to security@gitea.io instead of opening a public issue --> <!-- 1. Please speak English, this is the language all maintainers can speak and write. 2. Please ask questions or configuration/deploy problems on our Discord server (https://discord.gg/gitea) or forum (https://discourse.gitea.io). 3. Please take a moment to check that your issue doesn't already exist. 4. Please give all relevant information below for bug reports, because incomplete details will be handled as an invalid report. --> - Gitea version (or commit ref):the version of Gitea.com - go1.15.3 - Operating system: failed on windows but succeeded on macOS <!-- Please include information on whether you built gitea yourself, used one of our downloads or are using some other package --> <!-- Please also tell us how you are running gitea, e.g. if it is being run from docker, a command-line, systemd etc. ---> <!-- If you are using a package or systemd tell us what distribution you are using --> - Can you reproduce the bug at https://gitea.com: - Yes
GiteaMirror added the issue/confirmedtype/bug labels 2025-11-02 06:48:52 -06:00
Author
Owner

@6543 commented on GitHub (Oct 27, 2020):

"allowed_types": "image/*,application/zip,application/gzip,application/octet-stream,text/plain",
curl -X GET "https://gitea.com/api/v1/settings/attachment" -H "accept: application/json"

@6543 commented on GitHub (Oct 27, 2020): `"allowed_types": "image/*,application/zip,application/gzip,application/octet-stream,text/plain",` *curl -X GET "https://gitea.com/api/v1/settings/attachment" -H "accept: application/json"*
Author
Owner

@gymgym1212 commented on GitHub (Oct 27, 2020):

@6543 It seems that the application/zip doesn't work in windows. BTW, out of curiosity why the attachment types are different between issues and commits.

@gymgym1212 commented on GitHub (Oct 27, 2020): @6543 It seems that the `application/zip` doesn't work in windows. BTW, out of curiosity why the attachment types are different between issues and commits.
Author
Owner

@6543 commented on GitHub (Oct 27, 2020):

linux works too ... Tested it on Win10: I can confirm it - so its a Windows-Only-Problem

@6543 commented on GitHub (Oct 27, 2020): linux works too ... Tested it on Win10: I can confirm it - so its a Windows-Only-Problem
Author
Owner

@silverwind commented on GitHub (Oct 27, 2020):

gitea.com's config needs to be updated to extension-based allowed types as per cda44750cb to fix this. Or just use the defaults which match GH.

@silverwind commented on GitHub (Oct 27, 2020): gitea.com's config needs to be updated to extension-based allowed types as per https://github.com/go-gitea/gitea/commit/cda44750cbdc7a8460666a4f0ac7f652d84a3964 to fix this. Or just use the defaults which match GH.
Author
Owner

@lunny commented on GitHub (Oct 28, 2020):

I have updated allowed_types to allow .zip on https://gitea.com . And please create issues on https://gitea.com/gitea/gitea.com if the issue is gitea.com special one.

@lunny commented on GitHub (Oct 28, 2020): I have updated allowed_types to allow .zip on https://gitea.com . And please create issues on https://gitea.com/gitea/gitea.com if the issue is gitea.com special one.
Author
Owner

@silverwind commented on GitHub (Oct 30, 2020):

@gymgym1212 can you confirm it works now?

@silverwind commented on GitHub (Oct 30, 2020): @gymgym1212 can you confirm it works now?
Author
Owner

@gymgym1212 commented on GitHub (Nov 10, 2020):

Sorry for my silence, and it works now.

@gymgym1212 commented on GitHub (Nov 10, 2020): Sorry for my silence, and it works now.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/gitea#6221