summaryrefslogtreecommitdiff
path: root/lib
Commit message (Collapse)AuthorAgeFilesLines
* Merge branch 'fix-github-import-MR-wrong-project' into 'security' Robert Speicher2017-02-131-3/+7
| | | | | Fix labels being applied to wrong merge requests on GitHub import See https://dev.gitlab.org/gitlab/gitlabhq/merge_requests/2064
* Merge branch 'fix-rdoc-xss' into 'security' Robert Speicher2017-02-131-0/+3
| | | | | Fix XSS in rdoc and other markups See https://dev.gitlab.org/gitlab/gitlabhq/merge_requests/2058
* Merge branch 'asciidoctor-xss-patch' into 'security' Robert Speicher2017-02-131-0/+3
| | | | | Add sanitization filter to asciidocs output to prevent XSS See https://dev.gitlab.org/gitlab/gitlabhq/merge_requests/2057
* Merge branch 'fix-guest-access-posting-to-notes' into 'security' Robert Speicher2017-01-201-10/+16
| | | | | Prevent users from creating notes on resources they can't access See https://dev.gitlab.org/gitlab/gitlabhq/merge_requests/2054
* Merge branch 'fix-api-mr-permissions' into 'security' Robert Speicher2017-01-205-24/+21
| | | | | Ensure that only privileged users can access merge requests in the API See merge request !2053
* Merge branch 'fix-users-deleting-public-deployment-keys' into 'security' Robert Speicher2017-01-201-3/+7
| | | | | Fix users being able to delete instance public deployment keys See merge request !2049
* Merge branch 'fix-plain-text-emails' into 'master' Robert Speicher2017-01-091-2/+2
| | | | | | | Use #parts instead of #part to read all the parts of the Message. Closes #26463 See merge request !8507
* Merge branch '26051-fix-missing-endpoint-route-method' into 'master' Rémy Coutable2017-01-093-3/+21
| | | | | | | Don't instrument 405 Grape calls Closes #26051 See merge request !8445
* Merge branch 'fix-users-api-500-error' into 'master'Rémy Coutable2017-01-061-7/+4
| | | | | | | | Fix 500 errors when creating a user with identity via API Closes #26295 See merge request !8442
* Merge branch 'set_ldap_config_attributes_defaults' into 'master' Rémy Coutable2017-01-063-7/+15
| | | | | LDAP attributes needs default values See merge request !8465
* Merge branch 'fix/group-path-rename-error' into 'master' Douwe Maan2017-01-051-0/+3
| | | | | | | Fix error 500 renaming group. Also added specs and changelog. Closes #17922 and #23223 See merge request !8201
* Merge branch 'fix/cross-project-ref-path' into 'master' Sean McGivern2017-01-051-1/+1
| | | | | | | Fix cross-project references copy to include the project reference Closes #25890 See merge request !8232
* Merge branch 'fix-api-project-hooks-params' into 'master' Sean McGivern2017-01-051-1/+1
| | | | | | | Fix project hooks params Closes #26291 See merge request !8425
* Merge branch 'ldap_person_attributes' into 'master' Robert Speicher2017-01-051-2/+17
| | | | | | | Gitlab::LDAP::Person uses LDAP attributes configuration Closes #26290 See merge request !8418
* Merge branch 'api-fix-extern-uid-validation' into 'master' Sean McGivern2017-01-051-1/+1
| | | | | | | API: extern_uid is a string Closes #26227 See merge request !8404
* Merge branch 'zj-404-slack-error' into 'master' Kamil Trzciński2017-01-051-0/+7
| | | | | | | Add API route slack slash commands Closes #25954 See merge request !8362
* Merge branch ↵Douwe Maan2016-12-271-1/+4
| | | | | | | | | | '25931-gitlab-merge-request-view-crash-when-commiting-a-js-sourcemap-file' into 'master' Resolve "Gitlab merge request view crash when commiting a js sourcemap file" Closes #25931 See merge request !8310
* Merge branch 'auto-deploy-with-space' into 'master' Sean McGivern2016-12-271-2/+2
| | | | | | | Rename "autodeploy" to "auto deploy" Closes #25999 See merge request !8289
* Merge branch 'zj-fix-issue-search-chat-command' into 'master' Rémy Coutable2016-12-232-8/+9
| | | | | | | Fix errorcode 500 on slash commands Closes #26013 See merge request !8285
* Merge branch 'fixes-issues-api-reopen' into 'master' Rémy Coutable2016-12-231-2/+1
| | | | | | | Fix state_event parameter to reopen an issue Closes #25958 See merge request !8246
* Merge branch 'inline-math-dollar' into 'master' Robert Speicher2016-12-221-8/+3
| | | | | Don't render inline math when dollar signs are inside markup See merge request !8259
* Merge branch 'cache-last-commit-sha-for-path' into 'master' Yorick Peterse2016-12-221-1/+1
| | | | | Cache last commit id for path See merge request !8098
* Merge branch '24224-fix-project-ref-cache' into 'master' Douwe Maan2016-12-221-4/+15
| | | | | | | Fix lookup of project by unknown ref when caching is enabled Closes #24224 See merge request !7988
* Merge branch 'adam-auto-deploy' into 'master' Kamil Trzciński2016-12-211-2/+8
| | | | | | | Auto deploy Closes #23580 See merge request !8135
* Merge branch '22742-filter-protocol-relative-urls' into 'master' Rémy Coutable2016-12-211-1/+1
| | | | | | | Filter protocol-relative URLs in ExternalLinkFilter. Fixes issue #22742. Closes #22742 See merge request !6635
* Merge branch '25908-fix-grape-after-update' into 'master' Yorick Peterse2016-12-211-2/+2
| | | | | Use Grape's new Route methods See merge request !8223
* Merge branch 'zj-mattermost-slash-config' into 'master'Kamil Trzciński2016-12-215-9/+115
| | | | | | | | Mattermost slash auto config Closes #24769 See merge request !8070
* Merge branch 'fix/import-labels-error' into 'master' Douwe Maan2016-12-211-5/+23
| | | | | | | Fix Import/Export labels error Closes #24257 See merge request !8212
* Merge branch 'fix/import-export-build-token' into 'master' Grzegorz Bizon2016-12-211-0/+2
| | | | | | | | | | | | | | | | | | Fix duplicated build token problem importing projects Reset token so duplicated builds do not thrown an error on import - [x] [Changelog entry](https://docs.gitlab.com/ce/development/changelog.html) added - Tests - [x] Added for this feature/bug - [x] All builds are passing - [x] Conform by the [merge request performance guides](http://docs.gitlab.com/ce/development/merge_request_performance_guidelines.html) - [x] Conform by the [style guides](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CONTRIBUTING.md#style-guides) - [x] Branch has no merge conflicts with `master` (if it does - rebase it please) - [ ] [Squashed related commits together](https://git-scm.com/book/en/Git-Tools-Rewriting-History#Squashing-Commits) Fixes https://gitlab.com/gitlab-org/gitlab-ce/issues/23475 See merge request !8171
* Merge branch 'multipart-uploaded-file' into 'master' Rémy Coutable2016-12-211-2/+6
| | | | | | | Inject ::UploadedFile from Multipart middleware Closes #25888 See merge request !8215
* Merge branch '4269-public-files-api' into 'master' Sean McGivern2016-12-211-2/+0
| | | | | Allow unauthenticated access to Repositories Files API GET endpoints See merge request !8149
* Merge branch '4269-public-repositories-api' into 'master' Sean McGivern2016-12-211-6/+0
| | | | | | | Allow Repositories API GET endpoints to be requested anonymously Closes #4269 See merge request !8148
* Merge branch 'fix/detailed-status-groups' into 'master' Lin Jen-Shin (godfat)2016-12-214-10/+11
| | | | | | | | | | | | | | Improve icons and style for manual build status ## What does this MR do? This MR changes the CSS class for manual build status badge to make it a little more different than skipped build status badge. It makes it darker. ## Screenshots ![Screen_Shot_2016-12-17_at_13.37.58](/uploads/9628f0e84fdaad82d8833f546f0192a6/Screen_Shot_2016-12-17_at_13.37.58.png)![Screen_Shot_2016-12-17_at_13.31.48](/uploads/fe8e27df0274b9f9ae840110593a298a/Screen_Shot_2016-12-17_at_13.31.48.png) See merge request !8102
* Merge branch 'update-nginx-config-for-websockets' into 'master' Kamil Trzciński2016-12-212-0/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Update NGINX configuration files to add websocket support ## What does this MR do? Changes the bundled NGINX configuration files to support websockets introduced in https://gitlab.com/gitlab-org/gitlab-workhorse/merge_requests/83 These changes are also going into omnibus: https://gitlab.com/gitlab-org/omnibus-gitlab/merge_requests/1146 ## Are there points in the code the reviewer needs to double check? Best to wait until the omnibus MR is merged as the method may be changed. ## Why was this MR needed? Without it, NGINX won't let websockets through to workhorse. ## Screenshots (if relevant) ## Does this MR meet the acceptance criteria? - [x] [Documentation created/updated](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/doc/development/doc_styleguide.md) - Tests - [x] All builds are passing - [x] Conform by the [style guides](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CONTRIBUTING.md#style-guides) - [X] Branch has no merge conflicts with `master` (if it does - rebase it please) - [X] [Squashed related commits together](https://git-scm.com/book/en/Git-Tools-Rewriting-History#Squashing-Commits) ## What are the relevant issue numbers? Related to #22864 See merge request !8039
* Merge branch '22864-kubernetes-deploy-with-terminal' into 'master' Kamil Trzciński2016-12-212-0/+93
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add online terminal support for Kubernetes ## What does this MR do? Gives terminal access to kubernetes-deployed environments via the deployment service ## Are there points in the code the reviewer needs to double check? ## Why was this MR needed? Part of idea to production ## Screenshots (if relevant) ### `/root/reviewing/environments` ![Screen_Shot_2016-12-15_at_19.10.40](/uploads/bd2c54c07b6c85dec3328a20cd185b64/Screen_Shot_2016-12-15_at_19.10.40.png) ### `/root/reviewing/environments/10013` ![Screen_Shot_2016-12-19_at_12.52.39](/uploads/db4e4e06cda88437e8727433d65898b9/Screen_Shot_2016-12-19_at_12.52.39.png) ### `/root/reviewing/enviroments/10013/terminal` ![Screen_Shot_2016-12-15_at_02.35.52](/uploads/1bb77b7e2de2c657ae3bda62dc4f0970/Screen_Shot_2016-12-15_at_02.35.52.png) ## Does this MR meet the acceptance criteria? - [x] [Changelog entry](https://docs.gitlab.com/ce/development/changelog.html) added - [x] [Documentation created/updated](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/doc/development/doc_styleguide.md) - Tests - [X] Added for this feature/bug - [x] All builds are passing - [X] Conform by the [merge request performance guides](http://docs.gitlab.com/ce/development/merge_request_performance_guidelines.html) - [X] Conform by the [style guides](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CONTRIBUTING.md#style-guides) - [x] Branch has no merge conflicts with `master` (if it does - rebase it please) - [x] [Squashed related commits together](https://git-scm.com/book/en/Git-Tools-Rewriting-History#Squashing-Commits) ## What are the relevant issue numbers? * Closes #22864 #22958 * Alternative to, and somewhat based on, !6770 * Depends on https://gitlab.com/gitlab-org/gitlab-workhorse/merge_requests/83 See merge request !7690
* Merge branch 'fix-forbidden-for-build-api-for-deleted-project' into 'master' Grzegorz Bizon2016-12-212-15/+19
| | | | | | | | | Give forbidden if project for the build was deleted I guess we don't need a change log entry because this is just for an internal corner case fix. Closes #25309 See merge request !8091
* Merge branch 'fix-yaml-variables' into 'master' Grzegorz Bizon2016-12-212-1/+28
| | | | | | | | | | Convert CI YAML variables keys into strings So that this would be more consistent with the other variables, which all of them are string based. Closes #25554 See merge request !8088
* Merge branch 'dockerfile-templates' into 'master' Rémy Coutable2016-12-212-4/+38
| | | | | Allow to use Dockerfile templates See merge request !7247
* Merge branch 'zj-kamil-slack-slash-commands' into 'master'Grzegorz Bizon2016-12-215-12/+23
| | | | | | | | | | | | | Slack slash commands Implement Slack Slash Commands by utilizing generalized Mattermost presenter to fulfill Slack requirements. We want to expose Slack Slash Commands as a first-class service. Supersedes !8007 Closes #22182 See merge request !8126
* Merge branch '22348-gitea-importer' into 'master' Rémy Coutable2016-12-2110-147/+177
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It adds a brand new importer for Gitea! This is a continuation of !6945 started by @bkc. Gitea aims to be 100% GitHub-compatible but there's a few differences: - Gitea is not an OAuth provider (yet): https://github.com/go-gitea/gitea/issues/27 - This means we cannot map Gitea users given an assignee ID => assignees are not set on imported issues and merge requests - No releases API for now: https://github.com/go-gitea/gitea/issues/330 - API version is `v1` (GitHub is `v3`) - The IID field for milestones is `id` compared to `number` in GitHub. - Issues, PRs, milestones, labels don't have a `url` field (the importer now fallback to `''` in that case) **Known issues:** - Comments are not imported because comments JSON always have a blank `html_url`/`issue_url`/`pull_request_url`, so the IID cannot be extracted and the issuable cannot be found... :( This is tracked in https://github.com/go-gitea/gitea/issues/401, and solved by https://github.com/gogits/gogs/pull/3624 but this needs to be submitted / merged in Gitea. This is noted in the documentation. ## Are there points in the code the reviewer needs to double check? 1. I've made `Import::GiteaController` inherit from `Import::GithubController` since both controllers should be identical in the long-term and their current differences are small. 1. I've added a base `IssuableFormatter` class from which `IssueFormatter` & `PullRequestFormatter` inherit 1. I've added shared examples for GitHub/Gitea importer classes 1. I've made `Gitlab::ImportSources` more robust and tested! :christmas_tree: 1. I've added routing specs for import routes! :christmas_tree: Closes #22348 See merge request !8116
* Merge branch 'fix/import-export-ee-services' into 'master' Rémy Coutable2016-12-212-1/+8
| | | | | | | | | Fix missing service error importing from EE to CE Ignores services that are missing in the new instance (EE or even a customised instance), to avoid breaking the import. Fixes https://gitlab.com/gitlab-org/gitlab-ce/issues/23782 See merge request !8144
* Merge branch 'fix/import-export-mr-error' into 'master' Rémy Coutable2016-12-211-1/+1
| | | | | | | | | Fix import/export merge requests error When MWBS is set and the MR exported/imported an error gets thrown. We should ignore this so it can succeed as the merge user may no longer exist in the target instance. Fixes https://gitlab.com/gitlab-org/gitlab-ce/issues/24009 and https://gitlab.com/gitlab-com/support-forum/issues/1345 See merge request !8134
* Merge branch 'bb-wiki-import' into 'master' Douglas Barbosa Alexandre2016-12-213-1/+25
| | | | | | | | | | | | | | | | | | | | | | | | | | Add Wiki import to BB importer ## What does this MR do? Adds wiki importing - [ ] [Changelog entry](https://docs.gitlab.com/ce/development/changelog.html) added - [ ] [Documentation created/updated](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/doc/development/doc_styleguide.md) - [ ] API support added - Tests - [ ] Added for this feature/bug - [ ] All builds are passing - [ ] Conform by the [merge request performance guides](http://docs.gitlab.com/ce/development/merge_request_performance_guidelines.html) - [ ] Conform by the [style guides](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CONTRIBUTING.md#style-guides) - [ ] Branch has no merge conflicts with `master` (if it does - rebase it please) - [ ] [Squashed related commits together](https://git-scm.com/book/en/Git-Tools-Rewriting-History#Squashing-Commits) ## What are the relevant issue numbers? Closes https://gitlab.com/gitlab-org/gitlab-ce/issues/25819 See merge request !8180
* Merge branch '25895-fix-headers-in-ci-api-helpers' into 'master' Kamil Trzciński2016-12-211-1/+1
| | | | | | | Ensure nil User-Agent doesn't break the CI API Closes #25895 See merge request !8213
* Merge branch 'fix/25843' into 'master'Sean McGivern2016-12-201-2/+2
| | | | | | | | | | | | Rename SlackNotificationService back to SlackService See https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/8191#note_20310845 Closes https://gitlab.com/gitlab-org/gitlab-ce/issues/25843 /cc @yorickpeterse @stanhu @smcgivern @felipe_artur @ayufan See merge request !8208
* Merge branch '25848-fix-git-rev-list-env-parsing' into 'master' Sean McGivern2016-12-201-2/+2
| | | | | | | Reject blank environment variables in Gitlab::Git::RevList Closes #25848 See merge request !8189
* Merge branch '25301-git-2.11-force-push-bug' into 'master' Douglas Barbosa Alexandre2016-12-197-10/+71
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Accept environment variables from the `pre-receive` script ## Summary 1. Starting version 2.11, git changed the way the pre-receive flow works. - Previously, the new potential objects would be added to the main repo. If the pre-receive passes, the new objects stay in the repo but are linked up. If the pre-receive fails, the new objects stay orphaned in the repo, and are cleaned up during the next `git gc`. - In 2.11, the new potential objects are added to a temporary "alternate object directory", that git creates for this purpose. If the pre-receive passes, the objects from the alternate object directory are migrated to the main repo. If the pre-receive fails the alternate object directory is simply deleted. 2. In our workflow, the pre-recieve script (in `gitlab-shell`) calls the `/allowed` endpoint, which calls out directly to git to perform various checks. These direct calls to git do _not_ have the necessary environment variables set which allow access to the "alternate object directory" (explained above). Therefore these calls to git are not able to access any of the new potential objects to be added during this push. 3. We fix this by accepting the relevant environment variables (`GIT_ALTERNATE_OBJECT_DIRECTORIES`, `GIT_OBJECT_DIRECTORY`, and `GIT_QUARANTINE_PATH`) on the `/allowed` endpoint, and then include these environment variables while calling out to git. 4. This commit includes these environment variables while making the "force push" check. ## Issue Numbers - Closes #25301 (assuming the corresponding `gitlab-shell` MR has been merged in first) - Corresponding `gitlab-shell` MR: gitlab-org/gitlab-shell!112 - Corresponding EE MR: gitlab-org/gitlab-ee!964 ## Tasks - [#25301/!7967/!112] Git version 2.11.0 - Can't push to protected branch as master or developer - [x] Investigate - [x] Implementation - [x] `force_push.rb` should use the relevant environment variables - [x] Any other instances of `/allowed` calling out to git directly? - [x] Verify that the fix works over SSH as well - [x] Can we trim the number of env variables? Do we need all 3? - [x] Whitelist variables. Server shouldn't pass through _any_ env variable passed in - [x] Any security implications? - [x] Check for force push return code - [x] Shouldn't be able to opt-out from the force push check by passing an env variable - [x] Tests - [x] CE - [x] Added - [x] Passing - [x] Shell - [x] Added - [x] Passing - [x] Meta - [x] CHANGELOG entry created - [x] Branch has no merge conflicts with `master` - [x] Squashed related commits together - [x] EE merge request - [x] Review - [x] Endboss - [ ] Follow-up - [x] Make sure EE is working as expected - [x] [CE] Gitlab changes without gitlab-shell changes shouldn't raise any exceptions - [x] [CE] Gitlab-shell changes without gitlab changes shouldn't raise any exceptions - [x] [EE] Gitlab changes without gitlab-shell changes shouldn't raise any exceptions - [x] [EE] Gitlab-shell changes without gitlab changes shouldn't raise any exceptions - [ ] Wait for merge - [ ] CE - [ ] EE - [x] Shell See merge request !7967
* Fix rubocop failureszj-mattermost-sessionKamil Trzcinski2016-12-171-15/+21
|
* Store mattermost_url in settingsKamil Trzcinski2016-12-171-8/+9
|
* Improve Mattermost Session specsKamil Trzcinski2016-12-171-11/+12
|