{"action":"created","issue":{"url":"https://api.github.com/repos/owncloud/core/issues/33035","repository_url":"https://api.github.com/repos/owncloud/core","labels_url":"https://api.github.com/repos/owncloud/core/issues/33035/labels{/name}","comments_url":"https://api.github.com/repos/owncloud/core/issues/33035/comments","events_url":"https://api.github.com/repos/owncloud/core/issues/33035/events","html_url":"https://github.com/owncloud/core/pull/33035","id":367350292,"node_id":"MDExOlB1bGxSZXF1ZXN0MjIwODEwMzcy","number":33035,"title":"29873 read only mount","user":{"login":"TJHeeringa","id":16029718,"node_id":"MDQ6VXNlcjE2MDI5NzE4","avatar_url":"https://avatars3.githubusercontent.com/u/16029718?v=4","gravatar_id":"","url":"https://api.github.com/users/TJHeeringa","html_url":"https://github.com/TJHeeringa","followers_url":"https://api.github.com/users/TJHeeringa/followers","following_url":"https://api.github.com/users/TJHeeringa/following{/other_user}","gists_url":"https://api.github.com/users/TJHeeringa/gists{/gist_id}","starred_url":"https://api.github.com/users/TJHeeringa/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/TJHeeringa/subscriptions","organizations_url":"https://api.github.com/users/TJHeeringa/orgs","repos_url":"https://api.github.com/users/TJHeeringa/repos","events_url":"https://api.github.com/users/TJHeeringa/events{/privacy}","received_events_url":"https://api.github.com/users/TJHeeringa/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-10-05T20:05:36Z","updated_at":"2018-10-05T20:05:43Z","closed_at":null,"author_association":"NONE","pull_request":{"url":"https://api.github.com/repos/owncloud/core/pulls/33035","html_url":"https://github.com/owncloud/core/pull/33035","diff_url":"https://github.com/owncloud/core/pull/33035.diff","patch_url":"https://github.com/owncloud/core/pull/33035.patch"},"body":"<!--\r\nThanks for submitting a change to ownCloud!\r\n\r\nThis is the bug tracker for the Server component. Find other components at https://github.com/owncloud/core/blob/master/.github/CONTRIBUTING.md#guidelines\r\n\r\nFor fixing potential security issues please see https://owncloud.org/security/\r\n\r\nTo make it possible for us to get your change reviewed and merged please carefully fill out the requested information below.\r\n\r\nPlease note that any kind of change needs first be submitted to the master branch which holds the next major version of ownCloud.\r\n\r\nWe will carefully discuss if your change can or has to be backported to stable branches.\r\n\r\nPlease set the following labels:\r\n\r\n- Set label \"3 - To review\" for review or \"2 - Development\" in case the PR still has open tasks\r\n- Set label \"backport-request\" if backport is needed\r\n- Assignment: assign to self\r\n- Milestone: set the same as the ticket this PR fixes, or \"development\" by default\r\n- Reviewers: pick at least one\r\n-->\r\n\r\n## Description\r\n<!--- Describe your changes in detail -->\r\nTL;DR: Made a read only option for external storages\r\n\r\nI added a extra option in the advanced settings menu when mounting an external storage. This causes an extra row to be added in the database, when saving the mount, with whether an the mount is read only or not. A storagewrapper is added that checks the option and if the mount has the read only option the storagewrapper adds an permissionmask that makes the mount read only.\r\n\r\n## Related Issue\r\n<!--- This project only accepts pull requests related to open issues -->\r\n<!--- If suggesting a new feature or change, please discuss it in an issue first -->\r\n<!--- If fixing a bug, there should be an issue describing it with steps to reproduce -->\r\n<!--- Please link to the issue here: -->\r\n- Fixes https://github.com/owncloud/core/issues/29873\r\n\r\n## Motivation and Context\r\nSometimes you want to have a group only to be able to read a certain map. Currently no option exists to do this. Extra info can be found in:\r\nhttps://github.com/owncloud/user_management/issues/23\r\nhttps://github.com/owncloud/core/issues/29873\r\n\r\n## How Has This Been Tested?\r\nCurrently tested it by making a external share called 'Local' and setting the option `read_only` that I made. Haven't figured out how to write proper tests.\r\n\r\n## Screenshots (if appropriate):\r\n![capture](https://user-images.githubusercontent.com/16029718/46557054-e7b27400-c8e8-11e8-8aeb-119a245238c8.PNG)\r\n\r\n![capture_2](https://user-images.githubusercontent.com/16029718/46557028-d10c1d00-c8e8-11e8-9b9c-e689a2ab9948.PNG)\r\n\r\n![capture_3](https://user-images.githubusercontent.com/16029718/46557103-19c3d600-c8e9-11e8-9655-bf296681014a.PNG)\r\n\r\n\r\n## Types of changes\r\n<!--- What types of changes does your code introduce? Put an `x` in all the boxes that apply: -->\r\n- [ ] Bug fix (non-breaking change which fixes an issue)\r\n- [ x ] New feature (non-breaking change which adds functionality)\r\n- [ ] Breaking change (fix or feature that would cause existing functionality to change)\r\n- [ ] Technical debt\r\n- [ ] Tests\r\n\r\n## Checklist:\r\n<!-- Tick the checkboxes when done. -->\r\n<!-- Raise documentation ticket in https://github.com/owncloud/documentation -->\r\n- [ x ] Code changes\r\n- [ ] Unit tests added\r\n- [ ] Acceptance tests added\r\n- [ ] Documentation ticket raised: <link> \r\n\r\n## Open tasks:\r\n<!-- In case of incomplete PR, please list the open tasks here -->\r\n - [ ] Write tests\r\n - [ ] Figure out why `!$storage->instanceOfStorage('\\OC\\Files\\Storage\\Home'))` is required in the line `if ($mount->getOption('read_only', true) && !$storage->instanceOfStorage('\\OC\\Files\\Storage\\Home'))` on `lib/private/legacy/util.php` line 178"},"comment":{"url":"https://api.github.com/repos/owncloud/core/issues/comments/427483756","html_url":"https://github.com/owncloud/core/pull/33035#issuecomment-427483756","issue_url":"https://api.github.com/repos/owncloud/core/issues/33035","id":427483756,"node_id":"MDEyOklzc3VlQ29tbWVudDQyNzQ4Mzc1Ng==","user":{"login":"CLAassistant","id":11571300,"node_id":"MDQ6VXNlcjExNTcxMzAw","avatar_url":"https://avatars1.githubusercontent.com/u/11571300?v=4","gravatar_id":"","url":"https://api.github.com/users/CLAassistant","html_url":"https://github.com/CLAassistant","followers_url":"https://api.github.com/users/CLAassistant/followers","following_url":"https://api.github.com/users/CLAassistant/following{/other_user}","gists_url":"https://api.github.com/users/CLAassistant/gists{/gist_id}","starred_url":"https://api.github.com/users/CLAassistant/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/CLAassistant/subscriptions","organizations_url":"https://api.github.com/users/CLAassistant/orgs","repos_url":"https://api.github.com/users/CLAassistant/repos","events_url":"https://api.github.com/users/CLAassistant/events{/privacy}","received_events_url":"https://api.github.com/users/CLAassistant/received_events","type":"User","site_admin":false},"created_at":"2018-10-05T20:05:43Z","updated_at":"2018-10-05T20:05:43Z","author_association":"NONE","body":"[![CLA assistant check](https://cla-assistant.io/pull/badge/not_signed)](https://cla-assistant.io/owncloud/core?pullRequest=33035) <br/>Thank you for your submission, we really appreciate it. Like many open source projects, we ask that you all sign our [Contributor License Agreement](https://cla-assistant.io/owncloud/core?pullRequest=33035) before we can accept your contribution.<br/>**0** out of **2** committers have signed the CLA.<br/><br/>:x: TJHeeringa<br/>:x: TJ<br/><hr/>**TJ** seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please [add the email address used for this commit to your account](https://help.github.com/articles/why-are-my-commits-linked-to-the-wrong-user/#commits-are-not-linked-to-any-user).<br/><sub>You have signed the CLA already but the status is still pending? Let us [recheck](https://cla-assistant.io/check/owncloud/core?pullRequest=33035) it.</sub>"}}
{"actor":{"display_login":"CLAassistant"}}