aboutsummaryrefslogtreecommitdiff
path: root/routes
Commit message (Collapse)AuthorAge
* templates: make state changing routes to POST method (#5541)Unknwon2018-12-06
| | | | - pkg/context: add ParamsUser to unify the injection process
* user/auth: flush and destroy session at logout (#5540)Unknwon2018-12-04
| | | | Reported by @cezar97.
* vendor: update github.com/gogs/go-gogs-clientUnknwon2018-12-03
| | | | Bring fixes for #5538
* api/repo: support edit repository issue tracker (gogs/go-gogs-client#94)Unknwon2018-12-02
|
* routes/api: change status handle to new styleUnknwon2018-12-01
| | | | Also fixed one bug that did not catch team not found error.
* routes/api: allow get repository without login (#5475)Unknwon2018-12-01
|
* api: fix critical CSRF vulnerabilities on API routes (#5355)Unknwon2018-11-28
| | | | By explicitly requires token authentication.
* routes/repo/issue: implement issue pre-filling (#5521)Charles Kenney2018-11-20
| | | Signed-off-by: Charles Kenney <charlesc.kenney@gmail.com>
* repo/http: update CORS headers to allow custom user-agent (#5498)William Hilton2018-11-07
| | | At some point after #4970 was merged, isomorphic-git started sending a custom User-Agent in its HTTP requests to deal with some services (\*cough\* gists \*cough\*) which filtered git traffic by User-Agent. Sadly, this broke cloning from Gogs using isomorphic-git in the browser (https://github.com/isomorphic-git/isomorphic-git/issues/555). This PR fixes it by telling browsers it is OK for CORS requests to send a custom User-Agent header.
* routes/repo/issue: fix redirect with unexpected escape (#5443)Unknwon2018-09-30
|
* pkg/context: apply EscapePound at context levelUnknwon2018-09-28
| | | | | | Always escape template variable {{.Link}} variable and redirect calls. Relates to #5442
* routes: fix open redirect vulnerability (#5355)Unknwon2018-09-28
| | | | Reported by @cezar97.
* ci: fix go vet and add Go 1.11.xUnknwon2018-09-14
|
* repo: trigger webhook when delete branch after merged pull request (#5331)Unknwon2018-09-14
|
* auth: support set default login source (#5274)Unknwon2018-09-13
|
* login_source: add default authentication switch (#5338)haixunlu2018-09-13
| | | | | | | | | | | | | | | * Add default Authentication Switch. * adjust the code accroding to reviews * #1. Remove redudant logic. #2, Fix a bug in "Edit" panel. * Remove unused logic * Fix local authentication files are not flushed. * refactor according to review.
* repo/editor: hide internal error detailUnknwon2018-08-17
| | | | Prevent exposure of server path
* repo_editor: able to trigger Git hooks (#4338)Unknwon2018-08-17
|
* pkg/markup: allow match SHA1 length 7-40 (#3321)Unknwon2018-08-17
|
* routes: fix open redirect vulnerability #5364 (#5365)chromium13372018-08-06
|
* repo: fix issue of fork repository no check the limit of users' repository ↵GeekComb2018-07-18
| | | | (#5346)
* routes/repo/setting: require autosize when repo/settings/options is rendered ↵Steve Chung2018-06-26
| | | | (#5315)
* pull request: able to add custom commit description (#5276)ususdei2018-06-26
| | | | | | | | | | * pull request merges now allow for custom commit messages * allow i18n on commit_message label * place label above textarea for commit message * rename commit message for pull requests into commit description and pass to git separately
* repo: add changes to repository avatar feature (#5221)Unknwon2018-06-17
|
* repo: support avatars (#5221)Sergey Dryabzhinsky2018-06-17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * First code for repository avatars * Last code for repository avatars - add new option for repo avatars location on filesystem - add route catch in web - add new fields to repo model - add migration - update settings handlers - update repo header template * Update locale messages * Add repo avatars to home page * Add repo avatars to organization right panel * Show repo avatars in repo list * Remove AvatarEamil field, remove Gravatar support, use generic locale messages * Fix migration * Fix seed and not used tool * Revert public css changes, add them to less files * Latest lessc (2.6.0) don't put result into file but output to stdout So redirect output to file * Simplify things: - migration don't needed, and table changes too - just upload file to repo avatar storage - or generate random image * Fix repo image seed - name not unique * Get rid of not needed model fields * Class value is enough, remove height attribute * Don't generate random avatar for repository - use html and semantic ui icons if no avatar found * Update styles and templates for repo - use repo icon as default avatar - use globe icon for public repos - add micro style for repo avatars at dashboard * Remvoe redundant empty line * Fix nl2br filter - must return string * Fix css style for micro-repo-avatar in dashboard list * Remove `|len`, works fine w/o it. * Update after review 2: - use static route for repository avatar - format images settings block in settings * Update after review 2: - no random avatar for repo * Update after review 2: - no random avatar for repo 2 - update imports - update UploadAvatar* functions * Update after review 2: - update templates * Fix trace call * Remove unused immport since we use static route for repo avatars.
* routes/repo/http: fix wrong format typeUnknwon2018-06-13
|
* api: correct pagination in repository search api (#5293)oOOps2018-06-13
|
* repo: minor improve for PR #5219 and support UTF-8 byte countUnknwon2018-06-11
|
* repo: update repository description field to contain more than 256 symbols ↵Sergey Dryabzhinsky2018-06-11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (#5219) * Update repository description field to contain more than 256 symbols - update repository model - description field now is `TEXT` and limited by 4000 symbols - new migration - add description to html forms - repo creation and repo settings - add translation for description * Update for description field, new features - add autosize (height) for description textarea, new plugin - set max description length to 512 symbols - update locales * Fix migration - typo in var * Update repo description behaviour - add textarea autosize for /repo/create - add symbols counter under description testarea (create/edit) * Fix function definition - it a var * Revert ru-RU locale * Update by review - Use type `varchar(512)` in migration - Remove unused files from autosize plugin * Fix migration - new project paths * Fixes after review 2 - copyright year - format includes - use switch instead of multi-if * Remove unused `default:` option.
* *: use jsoniter to replace encoding/jsonUnknwon2018-06-09
|
* routes/repo: added deletion of an empty line at the end of file (#5261) (#5270)Alexey Terentyev2018-06-06
| | | | | | | | | | * Added deletion of an empty line at the end of file (#5261) Signed-off-by: Alexey Terentyev <axifnx@gmail.com> * Fix after feedback Signed-off-by: Alexey Terentyev <axifnx@gmail.com>
* mirror: show sync feeds on dashboard (#2017)Unknwon2018-05-30
|
* *: rename "gogits" to "gogs"Unknwon2018-05-27
|
* routes/user/setting: fix avatar email update error (#5245)Wei He2018-05-26
|
* routes/user/auth: improve coding styleUnknwon2018-05-21
|
* security: prevent same passcode from being reusedUnknwon2018-05-21
| | | | Reported by @cezar97.
* security: fix path cleanup for repository init and editor (#5207)Lauris BH2018-05-08
| | | Reported by Kacper Szurek https://security.szurek.pl/.
* templates/repo/issue: rework escape delete branch link after merged pull ↵Unknwon2018-04-16
| | | | request (#4601)
* auth: support authentication source config file (#3142)Unknwon2018-04-12
|
* MISC: fix typo and grammarUnknwon2018-03-30
| | | | Reference: https://github.com/gogits/gogs/commit/932490d7f137a2adf896e4e9326f4e8f2b9a2b54#commitcomment-28344918
* conf: add option to rewrite authorized_keys file at start (#4435)Unknwon2018-03-30
| | | | Added config option '[server] REWRITE_AUTHORIZED_KEYS_AT_START'.
* models: rename RewriteAllPublicKeys -> RewriteAuthorizedKeysUnknwon2018-03-30
|
* repo/http: add CORS headers to allow clone/push from browser agents (#4970)William Hilton2018-03-14
|
* repo: improve error handling for PR #4803Unknwon2018-03-08
|
* models: move ErrBranchNotExist to errors packageUnknwon2018-03-08
|
* repo: disallow web ui to delete protected branch after PR merged (#4803)bayangan19912018-03-08
| | | | | | | | | | * Disallow web ui to delete protected branch * Fix for branches not yet protected Had to change how error was handled. If a branch had not yet been protected the error would be generated. Reworked to start as false and then use the protected if it was found.
* repo/commit: fix file commit history pagination (#4965)Douglas Thrift2018-03-06
| | | | | - The `commits_table.tmpl` pagination uses a `$.FileName` variable in order to generate the next/previous URLs, but it seems like that variable was no longer being populated in `renderCommits`.
* MISC: minor fixes in webhookUnknwon2017-11-18
|
* pull_request: able to ignore whitespace when check conflict (#4834)Unknwon2017-11-16
|
* admin/config: add UI for [http] section (#3987)Unknwon2017-11-16
|