diff --git a/.bingo/Variables.mk b/.bingo/Variables.mk index 54a8f3c2f3f..282c1fc0575 100644 --- a/.bingo/Variables.mk +++ b/.bingo/Variables.mk @@ -47,11 +47,11 @@ $(GO_LICENSES): $(BINGO_DIR)/go-licenses.mod @echo "(re)installing $(GOBIN)/go-licenses-v1.0.1-0.20220408034444-fd2d9ec868aa" @cd $(BINGO_DIR) && $(GO) build -mod=mod -modfile=go-licenses.mod -o=$(GOBIN)/go-licenses-v1.0.1-0.20220408034444-fd2d9ec868aa "github.com/google/go-licenses" -GOLANGCI_LINT := $(GOBIN)/golangci-lint-v1.47.0 +GOLANGCI_LINT := $(GOBIN)/golangci-lint-v1.47.3 $(GOLANGCI_LINT): $(BINGO_DIR)/golangci-lint.mod @# Install binary/ries using Go 1.14+ build command. This is using bwplotka/bingo-controlled, separate go module with pinned dependencies. - @echo "(re)installing $(GOBIN)/golangci-lint-v1.47.0" - @cd $(BINGO_DIR) && $(GO) build -mod=mod -modfile=golangci-lint.mod -o=$(GOBIN)/golangci-lint-v1.47.0 "github.com/golangci/golangci-lint/cmd/golangci-lint" + @echo "(re)installing $(GOBIN)/golangci-lint-v1.47.3" + @cd $(BINGO_DIR) && $(GO) build -mod=mod -modfile=golangci-lint.mod -o=$(GOBIN)/golangci-lint-v1.47.3 "github.com/golangci/golangci-lint/cmd/golangci-lint" HUGO := $(GOBIN)/hugo-v0.94.0 $(HUGO): $(BINGO_DIR)/hugo.mod diff --git a/.bingo/golangci-lint.mod b/.bingo/golangci-lint.mod index 6a438823a28..d5bb739b459 100644 --- a/.bingo/golangci-lint.mod +++ b/.bingo/golangci-lint.mod @@ -2,4 +2,4 @@ module _ // Auto generated by https://github.com/bwplotka/bingo. DO NOT EDIT go 1.17 -require github.com/golangci/golangci-lint v1.47.0 // cmd/golangci-lint +require github.com/golangci/golangci-lint v1.47.3 // cmd/golangci-lint diff --git a/.bingo/golangci-lint.sum b/.bingo/golangci-lint.sum index c5078aa9a74..785ac534fa4 100644 --- a/.bingo/golangci-lint.sum +++ b/.bingo/golangci-lint.sum @@ -61,10 +61,12 @@ github.com/BurntSushi/toml v0.4.1 h1:GaI7EiDXDRfa8VshkTj7Fym7ha+y8/XxIgD2okUIjLw github.com/BurntSushi/toml v0.4.1/go.mod h1:CxXYINrC8qIiEnFrOxCa7Jy5BFHlXnUU2pbicEuybxQ= github.com/BurntSushi/toml v1.0.0 h1:dtDWrepsVPfW9H/4y7dDgFc2MBUSeJhlaDtK13CxFlU= github.com/BurntSushi/toml v1.1.0 h1:ksErzDEI1khOiGPgpwuI7x2ebx/uXQNw7xJpn9Eq1+I= +github.com/BurntSushi/toml v1.2.0 h1:Rt8g24XnyGTyglgET/PRUNlrUeu9F5L+7FilkXfZgs0= github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo= github.com/Djarvur/go-err113 v0.0.0-20210108212216-aea10b59be24 h1:sHglBQTwgx+rWPdisA5ynNEsoARbiCBOyGcJM4/OzsM= github.com/Djarvur/go-err113 v0.0.0-20210108212216-aea10b59be24/go.mod h1:4UJr5HIiMZrwgkSPdsjy2uOQExX/WEILpIrO9UPGuXs= github.com/GaijinEntertainment/go-exhaustruct/v2 v2.2.0 h1:V9xVvhKbLt7unNEGAruK1xXglyc668Pq3Xx0MNTNqpo= +github.com/GaijinEntertainment/go-exhaustruct/v2 v2.2.2 h1:DGdS4FlsdM6OkluXOhgkvwx05ZjD3Idm9WqtYnOmSuY= github.com/Masterminds/goutils v1.1.0/go.mod h1:8cTjp+g8YejhMuvIA5y2vz3BpJxksy863GQaJW2MFNU= github.com/Masterminds/semver v1.4.2/go.mod h1:MB6lktGJrhw8PrUyiEoblNEGEQ+RzHPF078ddwwvV3Y= github.com/Masterminds/semver v1.5.0 h1:H65muMkzWKEuNDnfl9d70GUjFniHKHRbFPGBuZ3QEww= @@ -83,6 +85,7 @@ github.com/alecthomas/units v0.0.0-20190717042225-c3de453c63f4/go.mod h1:ybxpYRF github.com/alexkohler/prealloc v1.0.0 h1:Hbq0/3fJPQhNkN0dR95AVrr6R7tou91y0uHG5pOcUuw= github.com/alexkohler/prealloc v1.0.0/go.mod h1:VetnK3dIgFBBKmg0YnD9F9x6Icjd+9cvfHR56wJVlKE= github.com/alingse/asasalint v0.0.10 h1:qqGPDTV0ff0tWHN/nnIlSdjlU/EwRPaUY4SfpE1rnms= +github.com/alingse/asasalint v0.0.11 h1:SFwnQXJ49Kx/1GghOFz1XGqHYKp21Kq1nHad/0WQRnw= github.com/andybalholm/brotli v1.0.2/go.mod h1:loMXtMfwqflxFJPmdbJO0a3KNoPuLBgiu3qAvBg8x/Y= github.com/andybalholm/brotli v1.0.3/go.mod h1:fO7iG3H7G2nSZ7m0zPUDn85XEX2GTukHGRSepvi9Eig= github.com/antihax/optional v0.0.0-20180407024304-ca021399b1a6/go.mod h1:V8iCPQYkqmusNa815XgQio277wI47sdRh1dUOLdyC6Q= @@ -162,6 +165,7 @@ github.com/daixiang0/gci v0.2.9 h1:iwJvwQpBZmMg31w+QQ6jsyZ54KEATn6/nfARbBNW294= github.com/daixiang0/gci v0.2.9/go.mod h1:+4dZ7TISfSmqfAGv59ePaHfNzgGtIkHAhhdKggP1JAc= github.com/daixiang0/gci v0.3.3 h1:55xJKH7Gl9Vk6oQ1cMkwrDWjAkT1D+D1G9kNmRcAIY4= github.com/daixiang0/gci v0.4.2 h1:PyT/Y4a265wDhPCZo2ip/YH33M4zEuFA3nDMdAvcKSA= +github.com/daixiang0/gci v0.5.0 h1:3+Z8nb/4dhJQYjpEbG4wt5na+KFJJTZ++PVEq/MVKX4= github.com/davecgh/go-spew v0.0.0-20161028175848-04cdfd42973b/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= @@ -302,6 +306,8 @@ github.com/golangci/golangci-lint v1.45.2 h1:9I3PzkvscJkFAQpTQi5Ga0V4qWdJERajX1U github.com/golangci/golangci-lint v1.45.2/go.mod h1:f20dpzMmUTRp+oYnX0OGjV1Au3Jm2JeI9yLqHq1/xsI= github.com/golangci/golangci-lint v1.47.0 h1:h2s+ZGGF63fdzUtac+VYUHPsEO0ADTqHouI7Vase+FY= github.com/golangci/golangci-lint v1.47.0/go.mod h1:3TZhfF5KolbIkXYjUFvER6G9CoxzLEaafr/u/QI1S5A= +github.com/golangci/golangci-lint v1.47.3 h1:ri7A2DgtFpxgqcMSsU3qIT0IBm/SCdYgXlvmJx4szUU= +github.com/golangci/golangci-lint v1.47.3/go.mod h1:IvT5xyPX1W8JUJJrV60gcMzgQe1ttW/38yAzn6LuHOk= github.com/golangci/lint-1 v0.0.0-20191013205115-297bf364a8e0 h1:MfyDlzVjl1hoaPzPD4Gpb/QgoRfSBR0jdhwGyAWwMSA= github.com/golangci/lint-1 v0.0.0-20191013205115-297bf364a8e0/go.mod h1:66R6K6P6VWk9I95jvqGxkqJxVWGFy9XlDwLwVz1RCFg= github.com/golangci/maligned v0.0.0-20180506175553-b1d89398deca h1:kNY3/svz5T29MYHubXix4aDDuE3RWHkPvopM/EDv/MA= @@ -695,6 +701,7 @@ github.com/russross/blackfriday v1.5.2/go.mod h1:JO/DiYxRf+HjHt06OyowR9PTA263kcR github.com/russross/blackfriday/v2 v2.0.1/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= github.com/ryancurrah/gomodguard v1.2.3 h1:ww2fsjqocGCAFamzvv/b8IsRduuHHeK2MHTcTxZTQX8= github.com/ryancurrah/gomodguard v1.2.3/go.mod h1:rYbA/4Tg5c54mV1sv4sQTP5WOPBcoLtnBZ7/TEhXAbg= +github.com/ryancurrah/gomodguard v1.2.4 h1:CpMSDKan0LtNGGhPrvupAoLeObRFjND8/tU1rEOtBp4= github.com/ryanrolds/sqlclosecheck v0.3.0 h1:AZx+Bixh8zdUBxUA1NxbxVAS78vTPq4rCb8OUZI9xFw= github.com/ryanrolds/sqlclosecheck v0.3.0/go.mod h1:1gREqxyTGR3lVtpngyFo3hZAgk0KCtEdgEkHwDbigdA= github.com/ryanuber/columnize v0.0.0-20160712163229-9b3edd62028f/go.mod h1:sm1tb6uqfes/u+d4ooFouqFdy9/2g9QGwK3SQygK0Ts= @@ -719,11 +726,14 @@ github.com/sirupsen/logrus v1.6.0/go.mod h1:7uNnSEd1DgxDLC74fIahvMZmmYsHGZGEOFrf github.com/sirupsen/logrus v1.7.0/go.mod h1:yWOB1SBYBC5VeMP7gHvWumXLIWorT60ONWic61uBYv0= github.com/sirupsen/logrus v1.8.1 h1:dJKuHgqk1NNQlqoA6BTlM1Wf9DOH3NBjQyu0h9+AZZE= github.com/sirupsen/logrus v1.8.1/go.mod h1:yWOB1SBYBC5VeMP7gHvWumXLIWorT60ONWic61uBYv0= +github.com/sirupsen/logrus v1.9.0 h1:trlNQbNUG3OdDrDil03MCb1H2o9nJ1x4/5LYw7byDE0= github.com/sivchari/containedctx v1.0.2 h1:0hLQKpgC53OVF1VT7CeoFHk9YKstur1XOgfYIc1yrHI= github.com/sivchari/nosnakecase v1.5.0 h1:ZBvAu1H3uteN0KQ0IsLpIFOwYgPEhKLyv2ahrVkub6M= +github.com/sivchari/nosnakecase v1.7.0 h1:7QkpWIRMe8x25gckkFd2A5Pi6Ymo0qgr4JrhGt95do8= github.com/sivchari/tenv v1.4.7 h1:FdTpgRlTue5eb5nXIYgS/lyVXSjugU8UUVDwhP1NLU8= github.com/sivchari/tenv v1.4.7/go.mod h1:5nF+bITvkebQVanjU6IuMbvIot/7ReNsUV7I5NbprB0= github.com/sivchari/tenv v1.6.0 h1:FyE4WysxLwYljKqWhTfOMjgKjBSnmzzg7lWOmpDiAcc= +github.com/sivchari/tenv v1.7.0 h1:d4laZMBK6jpe5PWepxlV9S+LC0yXqvYHiq8E6ceoVVE= github.com/smartystreets/assertions v0.0.0-20180927180507-b2de0cb4f26d/go.mod h1:OnSkiWE9lh6wB0YB77sQom3nweQdgAjqCqsofrRNTgc= github.com/smartystreets/goconvey v1.6.4/go.mod h1:syvi0/a8iFYH4r/RixwvyeAJjdLS9QV7WQ/tjFTllLA= github.com/soheilhy/cmux v0.1.4/go.mod h1:IM3LyeVVIOuxMH7sFAkER9+bJ4dT7Ms6E4xg4kGIyLM= @@ -841,6 +851,7 @@ github.com/yuin/goldmark v1.3.5/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1 github.com/yuin/goldmark v1.4.0/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1Zlc8k= gitlab.com/bosi/decorder v0.2.1 h1:ehqZe8hI4w7O4b1vgsDZw1YU1PE7iJXrQWFMsocbQ1w= gitlab.com/bosi/decorder v0.2.2 h1:LRfb3lP6mZWjUzpMOCLTVjcnl/SqZWBWmKNqQvMocQs= +gitlab.com/bosi/decorder v0.2.3 h1:gX4/RgK16ijY8V+BRQHAySfQAb354T7/xQpDB2n10P0= go.etcd.io/bbolt v1.3.3/go.mod h1:IbVyRI1SCnLcuJnV2u8VeU0CEYM7e686BmAb1XKL+uU= go.etcd.io/bbolt v1.3.4/go.mod h1:G5EMThwa9y8QZGBClrRx5EY+Yw9kAhnjy3bSjsnlVTQ= go.etcd.io/etcd v0.0.0-20200513171258-e048e166ab9c/go.mod h1:xCI7ZzBfRuGgBXyXO6yfWfDmlWd35khcWpUa4L0xI/k= @@ -898,6 +909,7 @@ golang.org/x/exp v0.0.0-20200207192155-f17229e696bd/go.mod h1:J/WKrq2StrnmMY6+EH golang.org/x/exp v0.0.0-20200224162631-6cc2880d07d6/go.mod h1:3jZMyOhIsHpP37uCMkUooju7aAi5cS1Q23tOzKc+0MU= golang.org/x/exp v0.0.0-20200331195152-e8c3332aa8e5/go.mod h1:4M0jN8W1tt0AVLNr8HDosyJCDCDuyL9N9+3m7wDWgKw= golang.org/x/exp/typeparams v0.0.0-20220218215828-6cf2b201936e h1:qyrTQ++p1afMkO4DPEeLGq/3oTsdlvdH4vqZUBWzUKM= +golang.org/x/exp/typeparams v0.0.0-20220613132600-b0d781184e0d h1:+W8Qf4iJtMGKkyAygcKohjxTk4JPsL9DpzApJ22m5Ic= golang.org/x/image v0.0.0-20190227222117-0694c2d4d067/go.mod h1:kZ7UVZpmo3dzQBMxlp+ypCbDeSB+sBbTgSJuh5dn5js= golang.org/x/image v0.0.0-20190802002840-cff245a6509b/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0= golang.org/x/lint v0.0.0-20181026193005-c67002cb31c3/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE= @@ -1005,6 +1017,7 @@ golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJ golang.org/x/sync v0.0.0-20201207232520-09787c993a3a/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20210220032951-036812b2e83c h1:5KslGYwFpkhGh+Q16bwMP3cOontH8FOep7tGV86Y7SQ= golang.org/x/sync v0.0.0-20210220032951-036812b2e83c/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4 h1:uVc8UZUe6tr40fFVnUP5Oj+veunVezqYl9z7DYw9xzw= golang.org/x/sys v0.0.0-20180823144017-11551d06cbcc/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= @@ -1085,6 +1098,7 @@ golang.org/x/sys v0.0.0-20211013075003-97ac67df715c h1:taxlMj0D/1sOAuv/CbSD+MMDo golang.org/x/sys v0.0.0-20211013075003-97ac67df715c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220209214540-3681064d5158 h1:rm+CHSpPEEW2IsXUib1ThaHIjuBVZjxNgSKmBLFfD4c= golang.org/x/sys v0.0.0-20220702020025-31831981b65f h1:xdsejrW/0Wf2diT5CPp3XmKUNbr7Xvw8kYilQ+6qjRY= +golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f h1:v4INt8xihDGvnrfjMDVXGxw9wrfxYyCjk0KbXjhR55s= golang.org/x/term v0.0.0-20201117132131-f5c789dd3221/go.mod h1:Nr5EML6q2oocZ2LXRh80K7BxOlk5/8JxuGnuhpl+muw= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/text v0.0.0-20170915032832-14c0d48ead0c/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= @@ -1206,6 +1220,7 @@ golang.org/x/tools v0.1.7 h1:6j8CgantCy3yc8JGBqkDLMKWqZ0RDU2g1HVgacojGWQ= golang.org/x/tools v0.1.7/go.mod h1:LGqMHiF4EqQNHR1JncWGqT5BVaXmza+X+BDGol+dOxo= golang.org/x/tools v0.1.10 h1:QjFRCZxdOhBJ/UNgnBZLbNV13DlbnK0quyivTnXJM20= golang.org/x/tools v0.1.11 h1:loJ25fNOEhSXfHrpoGj91eCUThwdNX6u24rO1xnNteY= +golang.org/x/tools v0.1.12 h1:VveCTK38A2rkS8ZqFY25HIDFscX5X9OoEhJd3quQmXU= golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= @@ -1395,6 +1410,7 @@ honnef.co/go/tools v0.2.1 h1:/EPr//+UMMXwMTkXvCCoaJDq8cpjMO80Ou+L4PDo2mY= honnef.co/go/tools v0.2.1/go.mod h1:lPVVZ2BS5TfnjLyizF7o7hv7j9/L+8cZY2hLyjP9cGY= honnef.co/go/tools v0.2.2 h1:MNh1AVMyVX23VUHE2O27jm6lNj3vjO5DexS4A1xvnzk= honnef.co/go/tools v0.3.2 h1:ytYb4rOqyp1TSa2EPvNVwtPQJctSELKaMyLfqNP4+34= +honnef.co/go/tools v0.3.3 h1:oDx7VAwstgpYpb3wv0oxiZlxY+foCpRAwY7Vk6XpAgA= mvdan.cc/gofumpt v0.1.1 h1:bi/1aS/5W00E2ny5q65w9SnKpWEF/UIOqDYBILpo9rA= mvdan.cc/gofumpt v0.1.1/go.mod h1:yXG1r1WqZVKWbVRtBWKWX9+CxGYfA51nSomhM0woR48= mvdan.cc/gofumpt v0.3.0 h1:kTojdZo9AcEYbQYhGuLf/zszYthRdhDNDUi2JKTxas4= @@ -1406,6 +1422,7 @@ mvdan.cc/lint v0.0.0-20170908181259-adc824a0674b/go.mod h1:2odslEg/xrtNQqCYg2/jC mvdan.cc/unparam v0.0.0-20210104141923-aac4ce9116a7 h1:HT3e4Krq+IE44tiN36RvVEb6tvqeIdtsVSsxmNPqlFU= mvdan.cc/unparam v0.0.0-20210104141923-aac4ce9116a7/go.mod h1:hBpJkZE8H/sb+VRFvw2+rBpHNsTBcvSpk61hr8mzXZE= mvdan.cc/unparam v0.0.0-20211214103731-d0ef000c54e5 h1:Jh3LAeMt1eGpxomyu3jVkmVZWW2MxZ1qIIV2TZ/nRio= +mvdan.cc/unparam v0.0.0-20220706161116-678bad134442 h1:seuXWbRB1qPrS3NQnHmFKLJLtskWyueeIzmLXghMGgk= rsc.io/binaryregexp v0.2.0/go.mod h1:qTv7/COck+e2FymRvadv62gMdZztPaShugOCi3I+8D8= rsc.io/quote/v3 v3.1.0/go.mod h1:yEA65RcK8LyAZtP9Kv3t0HmxON59tX3rD+tICJqUlj0= rsc.io/sampler v1.3.0/go.mod h1:T1hPZKmBbMNahiBKFy5HrXp6adAjACjK9JXDnKaTXpA= diff --git a/.bingo/variables.env b/.bingo/variables.env index baa1809bbfc..d36805336ba 100644 --- a/.bingo/variables.env +++ b/.bingo/variables.env @@ -18,7 +18,7 @@ CALENS="${GOBIN}/calens-v0.2.0" GO_LICENSES="${GOBIN}/go-licenses-v1.0.1-0.20220408034444-fd2d9ec868aa" -GOLANGCI_LINT="${GOBIN}/golangci-lint-v1.47.0" +GOLANGCI_LINT="${GOBIN}/golangci-lint-v1.47.3" HUGO="${GOBIN}/hugo-v0.94.0" diff --git a/.drone.env b/.drone.env index fb638d1514f..4cc690e0985 100644 --- a/.drone.env +++ b/.drone.env @@ -1,5 +1,5 @@ # The test runner source for API tests -CORE_COMMITID=dc5c1f5ce58b63ba9cf799ad81fe5cc50421f6da +CORE_COMMITID=76048f490ac50af03594d181c5baf49f87c18b6e CORE_BRANCH=master # The test runner source for UI tests diff --git a/.drone.star b/.drone.star index c0638c2fd7e..1ac30b73526 100644 --- a/.drone.star +++ b/.drone.star @@ -43,6 +43,10 @@ DEFAULT_NODEJS_VERSION = "14" dirs = { "base": "/drone/src", "web": "/drone/src/webTestRunner", + "zip": "/drone/src/zip", + "webZip": "/drone/src/zip/web.tar.gz", + "e2eYarnZip": "/drone/src/zip/e2e.tar.gz", + "acceptanceYarnZip": "/drone/src/zip/acceptance.tar.gz", # relative path from the base directory dirs["base"] # this is because the PLUGINS_S3_CACHE does not support absolute paths # PLUGINS_S3_CACHE is used to cache the core and testing app @@ -220,7 +224,7 @@ def main(ctx): test_pipelines = \ cancelPreviousBuilds() + \ - buildCacheWeb(ctx) + \ + buildWebCache(ctx) + \ [buildOcisBinaryForTesting(ctx)] + \ cacheCoreReposForTesting(ctx) + \ testOcisModules(ctx) + \ @@ -239,19 +243,7 @@ def main(ctx): test_pipelines.append( pipelineDependsOn( - purgeBuildArtifactCache(ctx, "ocis-binary-amd64"), - testPipelines(ctx), - ), - ) - test_pipelines.append( - pipelineDependsOn( - purgeBuildArtifactCache(ctx, "testrunner"), - testPipelines(ctx), - ), - ) - test_pipelines.append( - pipelineDependsOn( - purgeBuildArtifactCache(ctx, "testing_app"), + purgeBuildArtifactCache(ctx), testPipelines(ctx), ), ) @@ -282,11 +274,11 @@ def main(ctx): pipelineSanityChecks(ctx, pipelines) return pipelines -def buildCacheWeb(ctx): +def buildWebCache(ctx): return [{ "kind": "pipeline", "type": "docker", - "name": "cache-web", + "name": "build-web-cache", "clone": { "disable": True, }, @@ -821,7 +813,7 @@ def uiTestPipeline(ctx, filterTags, early_fail, runPart = 1, numberOfParts = 1, "name": "uploads", "temp": {}, }], - "depends_on": getPipelineNames([buildOcisBinaryForTesting(ctx)]), + "depends_on": getPipelineNames([buildOcisBinaryForTesting(ctx)] + buildWebCache(ctx)), "trigger": { "ref": [ "refs/heads/master", @@ -886,11 +878,13 @@ def e2eTests(ctx): "type": "docker", "name": "e2e-tests", "steps": e2eTestsSteps, - "depends_on": getPipelineNames([buildOcisBinaryForTesting(ctx)]), + "depends_on": getPipelineNames([buildOcisBinaryForTesting(ctx)] + buildWebCache(ctx)), "trigger": e2e_trigger, "volumes": e2e_volumes, }] + return [] + def uploadTracingResult(ctx): return [{ "name": "upload-tracing-result", @@ -1016,7 +1010,7 @@ def settingsUITests(ctx, storage = "ocis", accounts_hash_difficulty = 4): "name": "uploads", "temp": {}, }], - "depends_on": getPipelineNames([buildOcisBinaryForTesting(ctx)]), + "depends_on": getPipelineNames([buildOcisBinaryForTesting(ctx)] + buildWebCache(ctx)), "trigger": { "ref": [ "refs/heads/master", @@ -2161,7 +2155,7 @@ def checkStarlark(): }, }] -def genericCache(name, action, mounts, cache_key): +def genericCache(name, action, mounts, cache_path): rebuild = "false" restore = "false" if action == "rebuild": @@ -2187,16 +2181,18 @@ def genericCache(name, action, mounts, cache_key): "secret_key": { "from_secret": "cache_s3_secret_key", }, - "filename": "%s.tar" % (cache_key), + "filename": "%s.tar" % (name), + "path": cache_path, + "fallback_path": cache_path, }, } return step -def genericCachePurge(name, cache_key): +def genericCachePurge(flush_path): return { "kind": "pipeline", "type": "docker", - "name": "purge_%s" % (name), + "name": "purge_build_artifact_cache", "platform": { "os": "linux", "arch": "amd64", @@ -2216,8 +2212,8 @@ def genericCachePurge(name, cache_key): "from_secret": "cache_s3_endpoint", }, "flush": True, - "flush_age": "14", - "filename": "%s.tar" % (cache_key), + "flush_age": 1, + "flush_path": flush_path, }, }, ], @@ -2234,12 +2230,14 @@ def genericCachePurge(name, cache_key): } def genericBuildArtifactCache(ctx, name, action, path): - name = "%s_build_artifact_cache" % (name) - cache_key = "%s/%s/%s" % (ctx.repo.slug, ctx.build.commit + "-${DRONE_BUILD_NUMBER}", name) if action == "rebuild" or action == "restore": - return genericCache(name, action, [path], cache_key) + cache_path = "%s/%s/%s" % ("cache", ctx.repo.slug, ctx.build.commit + "-${DRONE_BUILD_NUMBER}") + name = "%s_build_artifact_cache" % (name) + return genericCache(name, action, [path], cache_path) + if action == "purge": - return genericCachePurge(name, cache_key) + flush_path = "%s/%s" % ("cache", ctx.repo.slug) + return genericCachePurge(flush_path) return [] def restoreBuildArtifactCache(ctx, name, path): @@ -2248,8 +2246,8 @@ def restoreBuildArtifactCache(ctx, name, path): def rebuildBuildArtifactCache(ctx, name, path): return [genericBuildArtifactCache(ctx, name, "rebuild", path)] -def purgeBuildArtifactCache(ctx, name): - return genericBuildArtifactCache(ctx, name, "purge", []) +def purgeBuildArtifactCache(ctx): + return genericBuildArtifactCache(ctx, "", "purge", []) def pipelineSanityChecks(ctx, pipelines): """pipelineSanityChecks helps the CI developers to find errors before running it @@ -2814,7 +2812,14 @@ def generateWebCache(ctx): "rm -rf %s" % dirs["web"], "git clone -b $WEB_BRANCH --single-branch --no-tags https://github.com/owncloud/web.git %s" % dirs["web"], "cd %s && git checkout $WEB_COMMITID" % dirs["web"], - "ls -la", + ], + }, + { + "name": "zip-web", + "image": OC_UBUNTU, + "commands": [ + "if [ ! -d '%s' ]; then mkdir -p %s; fi" % (dirs["zip"], dirs["zip"]), + "tar -czvf %s webTestRunner" % dirs["webZip"], ], }, { @@ -2825,7 +2830,7 @@ def generateWebCache(ctx): "source ./.drone.env", # cache using the minio/mc client to the 'owncloud' bucket (long term bucket) "mc alias set s3 $MC_HOST $AWS_ACCESS_KEY_ID $AWS_SECRET_ACCESS_KEY", - "mc mirror --overwrite --remove %s s3/$CACHE_BUCKET/ocis/web-test-runner/$WEB_COMMITID" % dirs["web"], + "mc cp -r -a %s s3/$CACHE_BUCKET/ocis/web-test-runner/$WEB_COMMITID" % dirs["webZip"], ], }, { @@ -2834,20 +2839,40 @@ def generateWebCache(ctx): "commands": [ "cd %s" % dirs["web"], "retry -t 3 'yarn install --immutable --frozen-lockfile'", - "cd %s/tests/acceptance" % dirs["web"], + "cd tests/acceptance", "retry -t 3 'yarn install --immutable --frozen-lockfile'", ], }, + { + "name": "zip-yarn", + "image": OC_CI_NODEJS % DEFAULT_NODEJS_VERSION, + "commands": [ + # zip the yarn deps before caching + "cd %s" % dirs["web"], + "tar -czvf %s .yarn" % dirs["e2eYarnZip"], + "cd tests/acceptance", + "tar -czvf %s .yarn" % dirs["acceptanceYarnZip"], + ], + }, { "name": "cache-yarn", "image": MINIO_MC, "environment": MINIO_MC_ENV, "commands": [ "source ./.drone.env", - # cache using the minio/mc client to the 'owncloud' bucket (long term bucket) + # cache using the minio/mc client to the public bucket (long term bucket) "mc alias set s3 $MC_HOST $AWS_ACCESS_KEY_ID $AWS_SECRET_ACCESS_KEY", - "mc mirror --overwrite --remove %s/.yarn s3/$CACHE_BUCKET/ocis/web-test-runner/yarn-e2e-$WEB_COMMITID" % dirs["web"], - "mc mirror --overwrite --remove %s/tests/acceptance/.yarn s3/$CACHE_BUCKET/ocis/web-test-runner/yarn-acceptance-$WEB_COMMITID" % dirs["web"], + "mc cp -r -a %s s3/$CACHE_BUCKET/ocis/web-test-runner/$WEB_COMMITID" % dirs["e2eYarnZip"], + "mc cp -r -a %s s3/$CACHE_BUCKET/ocis/web-test-runner/$WEB_COMMITID" % dirs["acceptanceYarnZip"], + ], + }, + { + "name": "list-web-cache", + "image": MINIO_MC, + "environment": MINIO_MC_ENV, + "commands": [ + "mc alias set s3 $MC_HOST $AWS_ACCESS_KEY_ID $AWS_SECRET_ACCESS_KEY", + "mc ls --recursive s3/$CACHE_BUCKET/ocis/web-test-runner", ], }, ] @@ -2859,10 +2884,16 @@ def restoreWebCache(): "environment": MINIO_MC_ENV, "commands": [ "source ./.drone.env", + "rm -rf %s" % dirs["web"], + "mkdir -p %s" % dirs["web"], "mc alias set s3 $MC_HOST $AWS_ACCESS_KEY_ID $AWS_SECRET_ACCESS_KEY", - "mc mirror s3/$CACHE_BUCKET/ocis/web-test-runner/$WEB_COMMITID %s" % dirs["web"], - "ls -la %s" % dirs["web"], - "chmod +x %s/tests/acceptance/*.sh" % dirs["web"], + "mc cp -r -a s3/$CACHE_BUCKET/ocis/web-test-runner/$WEB_COMMITID/web.tar.gz %s" % dirs["zip"], + ], + }, { + "name": "unzip-web-cache", + "image": OC_UBUNTU, + "commands": [ + "tar -xvf %s -C ." % dirs["webZip"], ], }] @@ -2874,15 +2905,16 @@ def restoreWebE2EYarnCache(): "commands": [ "source ./.drone.env", "mc alias set s3 $MC_HOST $AWS_ACCESS_KEY_ID $AWS_SECRET_ACCESS_KEY", - "mc mirror s3/$CACHE_BUCKET/ocis/web-test-runner/yarn-e2e-$WEB_COMMITID %s/.yarn" % dirs["web"], - "ls -la %s/.yarn" % dirs["web"], + "mc cp -r -a s3/$CACHE_BUCKET/ocis/web-test-runner/$WEB_COMMITID/e2e.tar.gz %s" % dirs["zip"], ], }, { # we need to install again becase the node_modules are not cached - "name": "install-yarn-e2e", + "name": "unzip-and-install-yarn-e2e", "image": OC_CI_NODEJS % DEFAULT_NODEJS_VERSION, "commands": [ "cd %s" % dirs["web"], + "rm -rf .yarn", + "tar -xvf %s" % dirs["e2eYarnZip"], "retry -t 3 'yarn install --immutable'", ], }] @@ -2895,15 +2927,16 @@ def restoreWebAcceptanceYarnCache(): "commands": [ "source ./.drone.env", "mc alias set s3 $MC_HOST $AWS_ACCESS_KEY_ID $AWS_SECRET_ACCESS_KEY", - "mc mirror s3/$CACHE_BUCKET/ocis/web-test-runner/yarn-acceptance-$WEB_COMMITID %s/tests/acceptance/.yarn" % dirs["web"], - "ls -la %s/tests/acceptance/.yarn" % dirs["web"], + "mc cp -r -a s3/$CACHE_BUCKET/ocis/web-test-runner/$WEB_COMMITID/acceptance.tar.gz %s" % dirs["zip"], ], }, { # we need to install again becase the node_modules are not cached - "name": "install-yarn-acceptance", + "name": "unzip-and-install-yarn-acceptance", "image": OC_CI_NODEJS % DEFAULT_NODEJS_VERSION, "commands": [ "cd %s/tests/acceptance" % dirs["web"], + "rm -rf .yarn", + "tar -xvf %s -C ." % dirs["acceptanceYarnZip"], "retry -t 3 'yarn install --immutable'", ], }] diff --git a/.golangci.yml b/.golangci.yml new file mode 100644 index 00000000000..11a419de011 --- /dev/null +++ b/.golangci.yml @@ -0,0 +1,160 @@ +linters: + enable-all: true + disable: + - contextcheck # FIXME: causes panic in graph service + - lll # 760 issues in the codebase + - exhaustivestruct + - exhaustruct + - exhaustive # 634 issues in the codebase + - wrapcheck # 398 issues in the codebase + - wsl # 379 issues in the codebase + - varnamelen # 305 issues in the codebase + - tagliatelle # 216 issues in the codebase + - godox + - forbidigo + - gochecknoglobals + - nlreturn + - nosnakecase # each 100-200 issues in codebase + - gci + - godot + - funlen + - gomnd + - gofumpt + - ireturn + - goerr113 + - containedctx + - paralleltest + - gocritic # each 50-100 issues in codebase + - whitespace + - cyclop + - noctx + - testpackage + - maligned + - golint + - forcetypeassert + - nonamedreturns + - dupl + - errorlint + - unparam + - stylecheck + - gocognit + - nestif # each 10-50 issues in codebase + +linters-settings: + gocyclo: + min-complexity: 35 # there are some func unforuntately who need this - should we refactor them? + +severity: + default-severity: error + +issues: + exclude-use-default: true + exclude-rules: + - path: _test.go + source: "." # exclude _test.go files from linting + include: # include comment errors. We want comments! + - EXC0002 + - EXC0011 + - EXC0012 + - EXC0013 + - EXC0014 + - EXC0015 + +# Enabled by default linters: +# deadcode: Finds unused code [fast: false, auto-fix: false] +# errcheck: Errcheck is a program for checking for unchecked errors in go programs. These unchecked errors can be critical bugs in some cases [fast: false, auto-fix: false] +# gosimple (megacheck): Linter for Go source code that specializes in simplifying code [fast: false, auto-fix: false] +# govet (vet, vetshadow): Vet examines Go source code and reports suspicious constructs, such as Printf calls whose arguments do not align with the format string [fast: false, auto-fix: false] +# ineffassign: Detects when assignments to existing variables are not used [fast: true, auto-fix: false] +# staticcheck (megacheck): It's a set of rules from staticcheck. It's not the same thing as the staticcheck binary. The author of staticcheck doesn't support or approve the use of staticcheck as a library inside golangci-lint. [fast: false, auto-fix: false] +# typecheck: Like the front-end of a Go compiler, parses and type-checks Go code [fast: false, auto-fix: false] +# unused (megacheck): Checks Go code for unused constants, variables, functions and types [fast: false, auto-fix: false] +# varcheck: Finds unused global variables and constants [fast: false, auto-fix: false] + +# Disabled by default linters: +# asasalint: check for pass []any as any in variadic func(...any) [fast: false, auto-fix: false] +# asciicheck: Simple linter to check that your code does not contain non-ASCII identifiers [fast: true, auto-fix: false] +# bidichk: Checks for dangerous unicode character sequences [fast: true, auto-fix: false] +# bodyclose: checks whether HTTP response body is closed successfully [fast: false, auto-fix: false] +# containedctx: containedctx is a linter that detects struct contained context.Context field [fast: true, auto-fix: false] +# contextcheck: check the function whether use a non-inherited context [fast: false, auto-fix: false] +# cyclop: checks function and package cyclomatic complexity [fast: false, auto-fix: false] +# decorder: check declaration order and count of types, constants, variables and functions [fast: true, auto-fix: false] +# depguard: Go linter that checks if package imports are in a list of acceptable packages [fast: true, auto-fix: false] +# dogsled: Checks assignments with too many blank identifiers (e.g. x, _, _, _, := f()) [fast: true, auto-fix: false] +# dupl: Tool for code clone detection [fast: true, auto-fix: false] +# durationcheck: check for two durations multiplied together [fast: false, auto-fix: false] +# errchkjson: Checks types passed to the json encoding functions. Reports unsupported types and optionally reports occasions, where the check for the returned error can be omitted. [fast: false, auto-fix: false] +# errname: Checks that sentinel errors are prefixed with the `Err` and error types are suffixed with the `Error`. [fast: false, auto-fix: false] +# errorlint: errorlint is a linter for that can be used to find code that will cause problems with the error wrapping scheme introduced in Go 1.13. [fast: false, auto-fix: false] +# execinquery: execinquery is a linter about query string checker in Query function which reads your Go src files and warning it finds [fast: false, auto-fix: false] +# exhaustive: check exhaustiveness of enum switch statements [fast: false, auto-fix: false] +# exhaustivestruct [deprecated]: Checks if all struct's fields are initialized [fast: false, auto-fix: false] +# exhaustruct: Checks if all structure fields are initialized [fast: false, auto-fix: false] +# exportloopref: checks for pointers to enclosing loop variables [fast: false, auto-fix: false] +# forbidigo: Forbids identifiers [fast: true, auto-fix: false] +# forcetypeassert: finds forced type assertions [fast: true, auto-fix: false] +# funlen: Tool for detection of long functions [fast: true, auto-fix: false] +# gci: Gci controls golang package import order and makes it always deterministic. [fast: true, auto-fix: false] +# gochecknoglobals: check that no global variables exist [fast: true, auto-fix: false] +# gochecknoinits: Checks that no init functions are present in Go code [fast: true, auto-fix: false] +# gocognit: Computes and checks the cognitive complexity of functions [fast: true, auto-fix: false] +# goconst: Finds repeated strings that could be replaced by a constant [fast: true, auto-fix: false] +# gocritic: Provides diagnostics that check for bugs, performance and style issues. [fast: false, auto-fix: false] +# gocyclo: Computes and checks the cyclomatic complexity of functions [fast: true, auto-fix: false] +# godot: Check if comments end in a period [fast: true, auto-fix: true] +# godox: Tool for detection of FIXME, TODO and other comment keywords [fast: true, auto-fix: false] +# goerr113: Golang linter to check the errors handling expressions [fast: false, auto-fix: false] +# gofmt: Gofmt checks whether code was gofmt-ed. By default this tool runs with -s option to check for code simplification [fast: true, auto-fix: true] +# gofumpt: Gofumpt checks whether code was gofumpt-ed. [fast: true, auto-fix: true] +# goheader: Checks is file header matches to pattern [fast: true, auto-fix: false] +# goimports: In addition to fixing imports, goimports also formats your code in the same style as gofmt. [fast: true, auto-fix: true] +# golint [deprecated]: Golint differs from gofmt. Gofmt reformats Go source code, whereas golint prints out style mistakes [fast: false, auto-fix: false] +# gomnd: An analyzer to detect magic numbers. [fast: true, auto-fix: false] +# gomoddirectives: Manage the use of 'replace', 'retract', and 'excludes' directives in go.mod. [fast: true, auto-fix: false] +# gomodguard: Allow and block list linter for direct Go module dependencies. This is different from depguard where there are different block types for example version constraints and module recommendations. [fast: true, auto-fix: false] +# goprintffuncname: Checks that printf-like functions are named with `f` at the end [fast: true, auto-fix: false] +# gosec (gas): Inspects source code for security problems [fast: false, auto-fix: false] +# grouper: An analyzer to analyze expression groups. [fast: true, auto-fix: false] +# ifshort: Checks that your code uses short syntax for if-statements whenever possible [fast: true, auto-fix: false] +# importas: Enforces consistent import aliases [fast: false, auto-fix: false] +# interfacer [deprecated]: Linter that suggests narrower interface types [fast: false, auto-fix: false] +# ireturn: Accept Interfaces, Return Concrete Types [fast: false, auto-fix: false] +# lll: Reports long lines [fast: true, auto-fix: false] +# maintidx: maintidx measures the maintainability index of each function. [fast: true, auto-fix: false] +# makezero: Finds slice declarations with non-zero initial length [fast: false, auto-fix: false] +# maligned [deprecated]: Tool to detect Go structs that would take less memory if their fields were sorted [fast: false, auto-fix: false] +# misspell: Finds commonly misspelled English words in comments [fast: true, auto-fix: true] +# nakedret: Finds naked returns in functions greater than a specified function length [fast: true, auto-fix: false] +# nestif: Reports deeply nested if statements [fast: true, auto-fix: false] +# nilerr: Finds the code that returns nil even if it checks that the error is not nil. [fast: false, auto-fix: false] +# nilnil: Checks that there is no simultaneous return of `nil` error and an invalid value. [fast: false, auto-fix: false] +# nlreturn: nlreturn checks for a new line before return and branch statements to increase code clarity [fast: true, auto-fix: false] +# noctx: noctx finds sending http request without context.Context [fast: false, auto-fix: false] +# nolintlint: Reports ill-formed or insufficient nolint directives [fast: true, auto-fix: false] +# nonamedreturns: Reports all named returns [fast: false, auto-fix: false] +# nosnakecase: nosnakecase is a linter that detects snake case of variable naming and function name. [fast: true, auto-fix: false] +# nosprintfhostport: Checks for misuse of Sprintf to construct a host with port in a URL. [fast: true, auto-fix: false] +# paralleltest: paralleltest detects missing usage of t.Parallel() method in your Go test [fast: false, auto-fix: false] +# prealloc: Finds slice declarations that could potentially be pre-allocated [fast: true, auto-fix: false] +# predeclared: find code that shadows one of Go's predeclared identifiers [fast: true, auto-fix: false] +# promlinter: Check Prometheus metrics naming via promlint [fast: true, auto-fix: false] +# revive: Fast, configurable, extensible, flexible, and beautiful linter for Go. Drop-in replacement of golint. [fast: false, auto-fix: false] +# rowserrcheck: checks whether Err of rows is checked successfully [fast: false, auto-fix: false] +# scopelint [deprecated]: Scopelint checks for unpinned variables in go programs [fast: true, auto-fix: false] +# sqlclosecheck: Checks that sql.Rows and sql.Stmt are closed. [fast: false, auto-fix: false] +# structcheck: Finds unused struct fields [fast: false, auto-fix: false] +# stylecheck: Stylecheck is a replacement for golint [fast: false, auto-fix: false] +# tagliatelle: Checks the struct tags. [fast: true, auto-fix: false] +# tenv: tenv is analyzer that detects using os.Setenv instead of t.Setenv since Go1.17 [fast: false, auto-fix: false] +# testpackage: linter that makes you use a separate _test package [fast: true, auto-fix: false] +# thelper: thelper detects golang test helpers without t.Helper() call and checks the consistency of test helpers [fast: false, auto-fix: false] +# tparallel: tparallel detects inappropriate usage of t.Parallel() method in your Go test codes [fast: false, auto-fix: false] +# unconvert: Remove unnecessary type conversions [fast: false, auto-fix: false] +# unparam: Reports unused function parameters [fast: false, auto-fix: false] +# varnamelen: checks that the length of a variable's name matches its scope [fast: false, auto-fix: false] +# wastedassign: wastedassign finds wasted assignment statements. [fast: false, auto-fix: false] +# whitespace: Tool for detection of leading and trailing whitespace [fast: true, auto-fix: true] +# wrapcheck: Checks that errors returned from external packages are wrapped [fast: false, auto-fix: false] +# wsl: Whitespace Linter - Forces you to use empty lines! [fast: true, auto-fix: false] + diff --git a/.make/go.mk b/.make/go.mk index 1dec932a094..dca874c8f85 100644 --- a/.make/go.mk +++ b/.make/go.mk @@ -64,13 +64,17 @@ go-mod-tidy: fmt: gofmt -s -w $(SOURCES) +.PHONY: golangci-lint-fix +golangci-lint-fix: $(GOLANGCI_LINT) + $(GOLANGCI_LINT) run $(LINTERS) --fix + .PHONY: golangci-lint golangci-lint: $(GOLANGCI_LINT) - $(GOLANGCI_LINT) run -E gosec -E bodyclose -E dogsled -E durationcheck -E revive -E ifshort -E makezero -E prealloc -E predeclared --path-prefix $(NAME) + $(GOLANGCI_LINT) run --path-prefix services/$(NAME) .PHONY: ci-golangci-lint ci-golangci-lint: $(GOLANGCI_LINT) - $(GOLANGCI_LINT) run -E gosec -E bodyclose -E dogsled -E durationcheck -E revive -E ifshort -E makezero -E prealloc -E predeclared --path-prefix $(NAME) --timeout 10m0s --issues-exit-code 0 --out-format checkstyle > checkstyle.xml + $(GOLANGCI_LINT) run --path-prefix services/$(NAME) --timeout 10m0s --issues-exit-code 0 --out-format checkstyle > checkstyle.xml .PHONY: test test: diff --git a/.vscode/launch.json b/.vscode/launch.json index 0ecba45fa3f..7eae3242115 100644 --- a/.vscode/launch.json +++ b/.vscode/launch.json @@ -1,6 +1,11 @@ { "version": "0.2.0", "configurations": [ + { + "name": "Listen for Xdebug", + "type": "php", + "request": "launch" + }, { "name": "oCIS server", "type": "go", diff --git a/CHANGELOG.md b/CHANGELOG.md index a9508d71e96..10f35bcc85a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,222 +6,65 @@ The following sections list the changes for unreleased. ## Summary -* Bugfix - Fix handling of invalid LDAP users and groups: [#4274](https://github.com/owncloud/ocis/issues/4274) -* Bugfix - Fix search in received shares: [#4308](https://github.com/owncloud/ocis/issues/4308) -* Bugfix - Substring search for sharees: [#547](https://github.com/owncloud/ocis/issues/547) -* Bugfix - Fix unrestricted quota on the graphAPI: [#4363](https://github.com/owncloud/ocis/pull/4363) -* Bugfix - Space Creators can hand over spaces: [#4244](https://github.com/owncloud/ocis/pull/4244) -* Enhancement - Add drives field to users endpoint: [#4072](https://github.com/owncloud/ocis/pull/4072) -* Enhancement - Improve validation of OIDC access tokens: [#3841](https://github.com/owncloud/ocis/issues/3841) -* Enhancement - Improve error log for "could not get user by claim" error: [#4227](https://github.com/owncloud/ocis/pull/4227) -* Enhancement - Allow providing list of services NOT to start: [#4254](https://github.com/owncloud/ocis/pull/4254) -* Enhancement - Introduce insecure flag for smtp email notifications: [#4279](https://github.com/owncloud/ocis/pull/4279) -* Enhancement - Fix behavior for foobar (in present tense): [#4346](https://github.com/owncloud/ocis/pull/4346) -* Enhancement - Use storageID when requesting special items: [#4356](https://github.com/owncloud/ocis/pull/4356) -* Enhancement - Update reva to v2.7.4: [#4294](https://github.com/owncloud/ocis/pull/4294) -* Enhancement - Update ownCloud Web to v5.7.0-rc.8: [#4314](https://github.com/owncloud/ocis/pull/4314) -* Enhancement - Expand personal drive on the graph user: [#4357](https://github.com/owncloud/ocis/pull/4357) +* Bugfix - Autocreate IDP private key also if file exists but is empty: [#4394](https://github.com/owncloud/ocis/pull/4394) +* Change - Rename "uploads purge" command to "uploads clean": [#4403](https://github.com/owncloud/ocis/pull/4403) +* Enhancement - Add /app/open-with-web endpoint: [#4376](https://github.com/owncloud/ocis/pull/4376) +* Enhancement - Added language option to the app provider: [#4399](https://github.com/owncloud/ocis/pull/4399) +* Enhancement - Added command to reset administrator password: [#4084](https://github.com/owncloud/ocis/issues/4084) +* Enhancement - Update reva to vx.x.x: [#4376](https://github.com/owncloud/ocis/pull/4376) ## Details -* Bugfix - Fix handling of invalid LDAP users and groups: [#4274](https://github.com/owncloud/ocis/issues/4274) +* Bugfix - Autocreate IDP private key also if file exists but is empty: [#4394](https://github.com/owncloud/ocis/pull/4394) - We fixed an issue where ocis would exit with a panic when LDAP users or groups where missing - required attributes (e.g. the id) + We've fixed the behavior for the IDP private key generation so that a private key is also + generated when the file already exists but is empty. - https://github.com/owncloud/ocis/issues/4274 + https://github.com/owncloud/ocis/pull/4394 -* Bugfix - Fix search in received shares: [#4308](https://github.com/owncloud/ocis/issues/4308) +* Change - Rename "uploads purge" command to "uploads clean": [#4403](https://github.com/owncloud/ocis/pull/4403) - We fixed a problem where items in received shares were not found. + We've renamed the storage-users service's "uploads purge" command to "upload clean". - https://github.com/owncloud/ocis/issues/4308 + https://github.com/owncloud/ocis/pull/4403 -* Bugfix - Substring search for sharees: [#547](https://github.com/owncloud/ocis/issues/547) +* Enhancement - Add /app/open-with-web endpoint: [#4376](https://github.com/owncloud/ocis/pull/4376) - We fixed searching for sharees to be no longer case-sensitive. With this we introduced two new - settings for the users and groups services: "group_substring_filter_type" for the group - services and "user_substring_filter_type" for the users service. They allow to set the type - of LDAP filter that is used for substring user searches. Possible values are: "initial", - "final" and "any" to do either prefix, suffix or full substring searches. Both settings - default to "initial". + We've added an /app/open-with-web endpoint to the app provider, so that clients that are no + browser or have only limited browser access can also open apps with the help of a Web URL. - Also a new option "search_min_length" was added for the "frontend" service. It allows to - configure the minimum number of characters to enter before a search for Sharees is started. - This setting is e.g. evaluated by the web ui via the capabilities endpoint. + https://github.com/owncloud/ocis/pull/4376 + https://github.com/cs3org/reva/pull/3143 - https://github.com/owncloud/ocis/issues/547 +* Enhancement - Added language option to the app provider: [#4399](https://github.com/owncloud/ocis/pull/4399) -* Bugfix - Fix unrestricted quota on the graphAPI: [#4363](https://github.com/owncloud/ocis/pull/4363) + We've added a language option to the app provider which will in the end be passed to the app a user + opens so that the web ui is displayed in the users language. - Unrestricted quota needs to show 0 on the API. It is not good for clients when the property is - missing. + https://github.com/owncloud/ocis/issues/4367 + https://github.com/owncloud/ocis/pull/4399 + https://github.com/cs3org/reva/pull/3156 - https://github.com/owncloud/ocis/pull/4363 +* Enhancement - Added command to reset administrator password: [#4084](https://github.com/owncloud/ocis/issues/4084) -* Bugfix - Space Creators can hand over spaces: [#4244](https://github.com/owncloud/ocis/pull/4244) + The new command `ocis idm resetpassword` allows to reset the administrator password when ocis + is not running. So it is possible to recover setups where the admin password was lost. - Set no owner on non personal spaces to be able to pass the space manager role to a new user. + https://github.com/owncloud/ocis/issues/4084 + https://github.com/owncloud/ocis/pull/4365 - https://github.com/owncloud/ocis/pull/4244 +* Enhancement - Update reva to vx.x.x: [#4376](https://github.com/owncloud/ocis/pull/4376) -* Enhancement - Add drives field to users endpoint: [#4072](https://github.com/owncloud/ocis/pull/4072) + Updated reva to version x.x.x. This update includes: - We have added `$expand=drives` to the `/users/{id}/` endpoint using the user filter - implemented in reva. + * TODO: - https://github.com/owncloud/ocis/pull/4072 - https://github.com/cs3org/reva/pull/3046 - https://github.com/owncloud/ocis/pull/4323 + https://github.com/owncloud/ocis/pull/4376 +# Changelog for [2.0.0-beta.6] (2022-08-11) -* Enhancement - Improve validation of OIDC access tokens: [#3841](https://github.com/owncloud/ocis/issues/3841) +The following sections list the changes for 2.0.0-beta.6. - Previously OIDC access tokes were only validated by requesting the userinfo from the IDP. It is - now possible to enable additional verification if the IDP issues access tokens in JWT format. - In that case the oCIS proxy service will now verify the signature of the token using the public - keys provided by jwks_uri endpoint of the IDP. It will also verify if the issuer claim (iss) - matches the expected values. - - The new validation is enabled by setting `PROXY_OIDC_ACCESS_TOKEN_VERIFY_METHOD` to - "jwt". Which is also the default. Setting it to "none" will disable the feature. - - https://github.com/owncloud/ocis/issues/3841 - https://github.com/owncloud/ocis/pull/4227 - -* Enhancement - Improve error log for "could not get user by claim" error: [#4227](https://github.com/owncloud/ocis/pull/4227) - - We've improved the error log for "could not get user by claim" error where previously only the - "nil" error has been logged. Now we're logging the message from the transport. - - https://github.com/owncloud/ocis/pull/4227 - -* Enhancement - Allow providing list of services NOT to start: [#4254](https://github.com/owncloud/ocis/pull/4254) - - Until now if one wanted to use a custom version of a service, one needed to provide - `OCIS_RUN_SERVICES` which is a list of all services to start. Now one can provide - `OCIS_EXCLUDE_RUN_SERVICES` which is a list of only services not to start - - https://github.com/owncloud/ocis/pull/4254 - -* Enhancement - Introduce insecure flag for smtp email notifications: [#4279](https://github.com/owncloud/ocis/pull/4279) - - We've introduced the `NOTIFICATIONS_SMTP_INSECURE` configuration option, that let's you - skip certificate verification for smtp email servers. - - https://github.com/owncloud/ocis/pull/4279 - -* Enhancement - Fix behavior for foobar (in present tense): [#4346](https://github.com/owncloud/ocis/pull/4346) - - We've added the configuration option `PROXY_OIDC_REWRITE_WELLKNOWN` to rewrite the - `/.well-known/openid-configuration` endpoint. If active, it serves the - `/.well-known/openid-configuration` response of the original IDP configured in - `OCIS_OIDC_ISSUER` / `PROXY_OIDC_ISSUER`. This is needed so that the Desktop Client, - Android Client and iOS Client can discover the OIDC identity provider. - - Previously this rewrite needed to be performed with an external proxy as NGINX or Traefik if an - external IDP was used. - - https://github.com/owncloud/ocis/issues/2819 - https://github.com/owncloud/ocis/issues/3280 - https://github.com/owncloud/ocis/pull/4346 - -* Enhancement - Use storageID when requesting special items: [#4356](https://github.com/owncloud/ocis/pull/4356) - - We need to use the storageID when requesting the special items of a space to spare a registry - lookup and improve the performance - - https://github.com/owncloud/ocis/pull/4356 - -* Enhancement - Update reva to v2.7.4: [#4294](https://github.com/owncloud/ocis/pull/4294) - - Updated reva to version 2.7.4 This update includes: - - * Bugfix [cs3org/reva#3141](https://github.com/cs3org/reva/pull/3141): Check ListGrants permission when listing shares - - Updated reva to version 2.7.3 This update includes: - - * Bugfix [cs3org/reva#3109](https://github.com/cs3org/reva/pull/3109): Bugfix missing check in MustCheckNodePermissions - * Bugfix [cs3org/reva#3086](https://github.com/cs3org/reva/pull/3086): Bugfix crash in ldap authprovider - * Bugfix [cs3org/reva#3094](https://github.com/cs3org/reva/pull/3094): Allow removing password from public links - * Bugfix [cs3org/reva#3096](https://github.com/cs3org/reva/pull/3096): Bugfix user filter - * Bugfix [cs3org/reva#3091](https://github.com/cs3org/reva/pull/3091): Project spaces need no real owner - * Bugfix [cs3org/reva#3088](https://github.com/cs3org/reva/pull/3088): Use correct sublogger - * Enhancement [cs3org/reva#3123](https://github.com/cs3org/reva/pull/3123): Allow stating links that have no permissions - * Enhancement [cs3org/reva#3087](https://github.com/cs3org/reva/pull/3087): Allow to set LDAP substring filter type - * Enhancement [cs3org/reva#3098](https://github.com/cs3org/reva/pull/3098): App provider http endpoint uses Form instead of Query - * Enhancement [cs3org/reva#3133](https://github.com/cs3org/reva/pull/3133): Admins can set quota on all spaces - * Enhancement [cs3org/reva#3117](https://github.com/cs3org/reva/pull/3117): Update go-ldap to v3.4.4 - * Enhancement [cs3org/reva#3095](https://github.com/cs3org/reva/pull/3095): Upload expiration and cleanup - - Https://github.com/owncloud/ocis/pull/4272 - https://github.com/cs3org/reva/pull/3096 https://github.com/cs3org/reva/pull/4315 - - https://github.com/owncloud/ocis/pull/4294 - https://github.com/owncloud/ocis/pull/4330 - https://github.com/owncloud/ocis/pull/4369 - -* Enhancement - Update ownCloud Web to v5.7.0-rc.8: [#4314](https://github.com/owncloud/ocis/pull/4314) - - Tags: web - - We updated ownCloud Web to v5.7.0-rc.9. Please refer to the changelog (linked) for details on - the web release. - - * Bugfix [owncloud/web#7080](https://github.com/owncloud/web/issues/7080): Add Droparea again - * Bugfix [owncloud/web#7357](https://github.com/owncloud/web/pull/7357): Batch deleting multiple files - * Bugfix [owncloud/web#7379](https://github.com/owncloud/web/pull/7379): Decline share not possible - * Bugfix [owncloud/web#7322](https://github.com/owncloud/web/pull/7322): Files pagination scroll to top - * Bugfix [owncloud/web#7348](https://github.com/owncloud/web/pull/7348): Left sidebar active navigation item has wrong cursor - * Bugfix [owncloud/web#7355](https://github.com/owncloud/web/pull/7355): Link indicator on "Shared via link"-page - * Bugfix [owncloud/web#7325](https://github.com/owncloud/web/pull/7325): Loading state in views - * Bugfix [owncloud/web#7344](https://github.com/owncloud/web/pull/7344): Missing file icon in details panel - * Bugfix [owncloud/web#7321](https://github.com/owncloud/web/pull/7321): Missing scroll bar in user management app - * Bugfix [owncloud/web#7334](https://github.com/owncloud/web/pull/7334): No redirect after disabling space - * Bugfix [owncloud/web#3071](https://github.com/owncloud/web/issues/3071): Don't leak oidc callback url into browser history - * Bugfix [owncloud/web#7379](https://github.com/owncloud/web/pull/7379): Open file on shared space resource not possible - * Bugfix [owncloud/web#7268](https://github.com/owncloud/web/issues/7268): Personal shares leaked into project space - * Bugfix [owncloud/web#7359](https://github.com/owncloud/web/pull/7359): Fix infinite loading spinner on invalid preview links - * Bugfix [owncloud/web#7272](https://github.com/owncloud/web/issues/7272): Print backend version - * Bugfix [owncloud/web#7424](https://github.com/owncloud/web/pull/7424): Quicklinks not shown - * Bugfix [owncloud/web#7379](https://github.com/owncloud/web/pull/7379): Rename shared space resource not possible - * Bugfix [owncloud/web#7210](https://github.com/owncloud/web/pull/7210): Repair navigation highlighter - * Bugfix [owncloud/web#7393](https://github.com/owncloud/web/pull/7393): Selected item bottom glue - * Bugfix [owncloud/web#7308](https://github.com/owncloud/web/pull/7308): "Shared with others" and "Shared via Link" resource links not working - * Bugfix [owncloud/web#7400](https://github.com/owncloud/web/issues/7400): Respect space quota permission - * Bugfix [owncloud/web#7349](https://github.com/owncloud/web/pull/7349): Missing quick actions in spaces file list - * Bugfix [owncloud/web#7396](https://github.com/owncloud/web/pull/7396): Add storage ID when navigating to a shared parent directory - * Bugfix [owncloud/web#7394](https://github.com/owncloud/web/pull/7394): Suppress active panel error log - * Bugfix [owncloud/web#7038](https://github.com/owncloud/web/issues/7038): File list render performance - * Bugfix [owncloud/web#7240](https://github.com/owncloud/web/issues/7240): Access token renewal during upload - * Bugfix [owncloud/web#7376](https://github.com/owncloud/web/pull/7376): Tooltips not shown on disabled create and upload button - * Bugfix [owncloud/web#7297](https://github.com/owncloud/web/pull/7297): Upload overlay progress bar spacing - * Bugfix [owncloud/web#7332](https://github.com/owncloud/web/pull/7332): Users list not loading if user has no role - * Bugfix [owncloud/web#7313](https://github.com/owncloud/web/pull/7313): Versions of shared files not visible - * Enhancement [owncloud/web#7404](https://github.com/owncloud/web/pull/7404): Adjust helper texts - * Enhancement [owncloud/web#7350](https://github.com/owncloud/web/pull/7350): Change file loading mechanism in `preview` app - * Enhancement [owncloud/web#7356](https://github.com/owncloud/web/pull/7356): Declined shares are now easily accessible - * Enhancement [owncloud/web#7365](https://github.com/owncloud/web/pull/7365): Drop menu styling in right sidebar - * Enhancement [owncloud/web#7252](https://github.com/owncloud/web/pull/7252): Redesign shared with list - * Enhancement [owncloud/web#7371](https://github.com/owncloud/web/pull/7371): Use fixed width for the right sidebar - * Enhancement [owncloud/web#7267](https://github.com/owncloud/web/pull/7267): Search all files announce limit - * Enhancement [owncloud/web#7364](https://github.com/owncloud/web/pull/7364): Sharing panel show label instead of description for links - * Enhancement [owncloud/web#7355](https://github.com/owncloud/web/pull/7355): Update ODS to v14.0.0-alpha.12 - * Enhancement [owncloud/web#7375](https://github.com/owncloud/web/pull/7375): User management app saved dialog - - https://github.com/owncloud/ocis/pull/4314 - https://github.com/owncloud/web/releases/tag/v5.7.0-rc.8 - -* Enhancement - Expand personal drive on the graph user: [#4357](https://github.com/owncloud/ocis/pull/4357) - - We can now list the personal drive on the users endpoint via the graph API. A user can add an - `$expand=drive` query to list the personal drive of the requested user. - - https://github.com/owncloud/ocis/pull/4357 -# Changelog for [2.0.0-beta.5] (2022-07-19) - -The following sections list the changes for 2.0.0-beta.5. - -[2.0.0-beta.5]: https://github.com/owncloud/ocis/compare/v1.20.0...v2.0.0-beta.5 +[2.0.0-beta.6]: https://github.com/owncloud/ocis/compare/v1.20.0...v2.0.0-beta.6 ## Summary @@ -238,6 +81,7 @@ The following sections list the changes for 2.0.0-beta.5. * Bugfix - Fix search index getting out of sync: [#3851](https://github.com/owncloud/ocis/pull/3851) * Bugfix - Inconsistency env var naming for LDAP filter configuration: [#3890](https://github.com/owncloud/ocis/issues/3890) * Bugfix - Fix LDAP insecure options: [#3897](https://github.com/owncloud/ocis/pull/3897) +* Bugfix - Fix handling of invalid LDAP users and groups: [#4274](https://github.com/owncloud/ocis/issues/4274) * Bugfix - Fix logging levels: [#4102](https://github.com/owncloud/ocis/pull/4102) * Bugfix - Fix `OCIS_RUN_SERVICES`: [#4133](https://github.com/owncloud/ocis/pull/4133) * Bugfix - Set default name for public link via capabilities: [#3834](https://github.com/owncloud/ocis/pull/3834) @@ -248,12 +92,15 @@ The following sections list the changes for 2.0.0-beta.5. * Bugfix - Remove unused OCS storage configuration: [#3955](https://github.com/owncloud/ocis/pull/3955) * Bugfix - Fix the `ocis search` command: [#3796](https://github.com/owncloud/ocis/pull/3796) * Bugfix - Rename search env variable for the grpc server address: [#3800](https://github.com/owncloud/ocis/pull/3800) +* Bugfix - Fix search in received shares: [#4308](https://github.com/owncloud/ocis/issues/4308) * Bugfix - Fix make sensitive config values in the proxy's debug server: [#4086](https://github.com/owncloud/ocis/pull/4086) * Bugfix - Fix the idm and settings extensions' admin user id configuration option: [#3799](https://github.com/owncloud/ocis/pull/3799) +* Bugfix - Substring search for sharees: [#547](https://github.com/owncloud/ocis/issues/547) * Bugfix - Fix configuration validation for extensions' server commands: [#3911](https://github.com/owncloud/ocis/pull/3911) * Bugfix - Fix startup error logging: [#4093](https://github.com/owncloud/ocis/pull/4093) * Bugfix - Fix multiple storage-users env variables: [#3802](https://github.com/owncloud/ocis/pull/3802) * Bugfix - Thumbnails for `/dav/xxx?preview=1` requests: [#3567](https://github.com/owncloud/ocis/pull/3567) +* Bugfix - Fix unrestricted quota on the graphAPI: [#4363](https://github.com/owncloud/ocis/pull/4363) * Bugfix - Fix user autoprovisioning: [#3893](https://github.com/owncloud/ocis/issues/3893) * Bugfix - Fix version info: [#3953](https://github.com/owncloud/ocis/pull/3953) * Bugfix - Fix version number in status page: [#3788](https://github.com/owncloud/ocis/issues/3788) @@ -267,6 +114,7 @@ The following sections list the changes for 2.0.0-beta.5. * Bugfix - Polish search: [#4094](https://github.com/owncloud/ocis/pull/4094) * Bugfix - Save Katherine: [#3823](https://github.com/owncloud/ocis/issues/3823) * Bugfix - Fix Thumbnails for IDs without a trailing path: [#3791](https://github.com/owncloud/ocis/pull/3791) +* Bugfix - Space Creators can hand over spaces: [#4244](https://github.com/owncloud/ocis/pull/4244) * Bugfix - URL encode the webdav url in the graph API: [#3597](https://github.com/owncloud/ocis/pull/3597) * Bugfix - Store user passwords hashed in idm: [#3778](https://github.com/owncloud/ocis/issues/3778) * Change - Update ocis packages and imports to V2: [#3678](https://github.com/owncloud/ocis/pull/3678) @@ -283,16 +131,22 @@ The following sections list the changes for 2.0.0-beta.5. * Change - Use the spaceID on the cs3 resource: [#4748](https://github.com/owncloud/ocis/pull/4748) * Change - Split MachineAuth from SystemUser: [#3672](https://github.com/owncloud/ocis/pull/3672) * Enhancement - Add capability for alias links: [#3983](https://github.com/owncloud/ocis/issues/3983) +* Enhancement - Add drives field to users endpoint: [#4072](https://github.com/owncloud/ocis/pull/4072) * Enhancement - Add FRONTEND_ENABLE_RESHARING env variable: [#4023](https://github.com/owncloud/ocis/pull/4023) * Enhancement - Add number of total matches to the search result: [#4189](https://github.com/owncloud/ocis/issues/4189) * Enhancement - Align service naming: [#3606](https://github.com/owncloud/ocis/pull/3606) * Enhancement - Add acting user to the audit log: [#3753](https://github.com/owncloud/ocis/issues/3753) * Enhancement - Add audit events for created containers: [#3941](https://github.com/owncloud/ocis/pull/3941) * Enhancement - Don't setup demo role assignments on default: [#3661](https://github.com/owncloud/ocis/issues/3661) +* Enhancement - Improve validation of OIDC access tokens: [#3841](https://github.com/owncloud/ocis/issues/3841) +* Enhancement - Improve error log for "could not get user by claim" error: [#4227](https://github.com/owncloud/ocis/pull/4227) * Enhancement - Introduce service registry cache: [#3833](https://github.com/owncloud/ocis/pull/3833) * Enhancement - Reintroduce user autoprovisioning in proxy: [#3860](https://github.com/owncloud/ocis/pull/3860) * Enhancement - Disable the color logging in docker compose examples: [#871](https://github.com/owncloud/ocis/issues/871) +* Enhancement - Allow providing list of services NOT to start: [#4254](https://github.com/owncloud/ocis/pull/4254) +* Enhancement - Introduce insecure flag for smtp email notifications: [#4279](https://github.com/owncloud/ocis/pull/4279) * Enhancement - Optional events in graph service: [#55555](https://github.com/owncloud/ocis/pull/55555) +* Enhancement - Fix behavior for foobar (in present tense): [#4346](https://github.com/owncloud/ocis/pull/4346) * Enhancement - Add config option to provide TLS certificate: [#3818](https://github.com/owncloud/ocis/issues/3818) * Enhancement - Add descriptions for graph-explorer config: [#3759](https://github.com/owncloud/ocis/pull/3759) * Enhancement - Add /me/changePassword endpoint to GraphAPI: [#3063](https://github.com/owncloud/ocis/issues/3063) @@ -306,11 +160,13 @@ The following sections list the changes for 2.0.0-beta.5. * Enhancement - Add initial version of the search extensions: [#3635](https://github.com/owncloud/ocis/pull/3635) * Enhancement - Add capability for public link single file edit: [#6787](https://github.com/owncloud/web/pull/6787) * Enhancement - Added `share_jail` and `projects` feature flags in spaces capability: [#3626](https://github.com/owncloud/ocis/pull/3626) +* Enhancement - Use storageID when requesting special items: [#4356](https://github.com/owncloud/ocis/pull/4356) * Enhancement - Add description tags to the thumbnails config structs: [#3752](https://github.com/owncloud/ocis/pull/3752) * Enhancement - Make thumbnails service log less noisy: [#3959](https://github.com/owncloud/ocis/pull/3959) * Enhancement - Update linkshare capabilities: [#3579](https://github.com/owncloud/ocis/pull/3579) * Enhancement - Update reva: [#3944](https://github.com/owncloud/ocis/pull/3944) * Enhancement - Update reva to version 2.7.2: [#4115](https://github.com/owncloud/ocis/pull/4115) +* Enhancement - Update reva to v2.7.4: [#4294](https://github.com/owncloud/ocis/pull/4294) * Enhancement - Update reva to version 2.4.1: [#3746](https://github.com/owncloud/ocis/pull/3746) * Enhancement - Update reva to version 2.5.1: [#3932](https://github.com/owncloud/ocis/pull/3932) * Enhancement - Update reva to v2.3.1: [#3552](https://github.com/owncloud/ocis/pull/3552) @@ -319,6 +175,8 @@ The following sections list the changes for 2.0.0-beta.5. * Enhancement - Update ownCloud Web to v5.5.0-rc.6: [#6854](https://github.com/owncloud/web/pull/6854) * Enhancement - Update ownCloud Web to v5.7.0-rc.1: [#4005](https://github.com/owncloud/ocis/pull/4005) * Enhancement - Update ownCloud Web to v5.7.0-rc.4: [#4140](https://github.com/owncloud/ocis/pull/4140) +* Enhancement - Update ownCloud Web to v5.7.0-rc.8: [#4314](https://github.com/owncloud/ocis/pull/4314) +* Enhancement - Expand personal drive on the graph user: [#4357](https://github.com/owncloud/ocis/pull/4357) * Enhancement - Add descriptions to webdav configuration: [#3755](https://github.com/owncloud/ocis/pull/3755) * Enhancement - Search service at the old webdav endpoint: [#4118](https://github.com/owncloud/ocis/pull/4118) @@ -437,6 +295,13 @@ The following sections list the changes for 2.0.0-beta.5. https://github.com/owncloud/ocis/pull/3897 +* Bugfix - Fix handling of invalid LDAP users and groups: [#4274](https://github.com/owncloud/ocis/issues/4274) + + We fixed an issue where ocis would exit with a panic when LDAP users or groups where missing + required attributes (e.g. the id) + + https://github.com/owncloud/ocis/issues/4274 + * Bugfix - Fix logging levels: [#4102](https://github.com/owncloud/ocis/pull/4102) We've fixed the configuration of logging levels. Previously it was not possible to configure a @@ -532,6 +397,12 @@ The following sections list the changes for 2.0.0-beta.5. https://github.com/owncloud/ocis/pull/3800 +* Bugfix - Fix search in received shares: [#4308](https://github.com/owncloud/ocis/issues/4308) + + We fixed a problem where items in received shares were not found. + + https://github.com/owncloud/ocis/issues/4308 + * Bugfix - Fix make sensitive config values in the proxy's debug server: [#4086](https://github.com/owncloud/ocis/pull/4086) We've fixed a security issue of the proxy's debug server config report endpoint. Previously @@ -548,6 +419,21 @@ The following sections list the changes for 2.0.0-beta.5. https://github.com/owncloud/ocis/pull/3799 +* Bugfix - Substring search for sharees: [#547](https://github.com/owncloud/ocis/issues/547) + + We fixed searching for sharees to be no longer case-sensitive. With this we introduced two new + settings for the users and groups services: "group_substring_filter_type" for the group + services and "user_substring_filter_type" for the users service. They allow to set the type + of LDAP filter that is used for substring user searches. Possible values are: "initial", + "final" and "any" to do either prefix, suffix or full substring searches. Both settings + default to "initial". + + Also a new option "search_min_length" was added for the "frontend" service. It allows to + configure the minimum number of characters to enter before a search for Sharees is started. + This setting is e.g. evaluated by the web ui via the capabilities endpoint. + + https://github.com/owncloud/ocis/issues/547 + * Bugfix - Fix configuration validation for extensions' server commands: [#3911](https://github.com/owncloud/ocis/pull/3911) We've fixed the configuration validation for the extensions' server commands. Before this @@ -587,6 +473,13 @@ The following sections list the changes for 2.0.0-beta.5. https://github.com/owncloud/ocis/pull/3567 +* Bugfix - Fix unrestricted quota on the graphAPI: [#4363](https://github.com/owncloud/ocis/pull/4363) + + Unrestricted quota needs to show 0 on the API. It is not good for clients when the property is + missing. + + https://github.com/owncloud/ocis/pull/4363 + * Bugfix - Fix user autoprovisioning: [#3893](https://github.com/owncloud/ocis/issues/3893) We've fixed the autoprovsioning feature that was introduced in beta2. Due to a bug the role @@ -681,6 +574,12 @@ The following sections list the changes for 2.0.0-beta.5. https://github.com/owncloud/ocis/pull/3791 +* Bugfix - Space Creators can hand over spaces: [#4244](https://github.com/owncloud/ocis/pull/4244) + + Set no owner on non personal spaces to be able to pass the space manager role to a new user. + + https://github.com/owncloud/ocis/pull/4244 + * Bugfix - URL encode the webdav url in the graph API: [#3597](https://github.com/owncloud/ocis/pull/3597) Fixed the webdav URL in the drives responses. Without encoding the URL could be broken by files @@ -812,6 +711,15 @@ The following sections list the changes for 2.0.0-beta.5. https://github.com/owncloud/ocis/issues/3983 https://github.com/owncloud/ocis/pull/3991 +* Enhancement - Add drives field to users endpoint: [#4072](https://github.com/owncloud/ocis/pull/4072) + + We have added `$expand=drives` to the `/users/{id}/` endpoint using the user filter + implemented in reva. + + https://github.com/owncloud/ocis/pull/4072 + https://github.com/cs3org/reva/pull/3046 + https://github.com/owncloud/ocis/pull/4323 + * Enhancement - Add FRONTEND_ENABLE_RESHARING env variable: [#4023](https://github.com/owncloud/ocis/pull/4023) We introduced resharing which was enabled by default, this is now configurable and can be @@ -854,6 +762,27 @@ The following sections list the changes for 2.0.0-beta.5. https://github.com/owncloud/ocis/issues/3661 https://github.com/owncloud/ocis/pull/3956 +* Enhancement - Improve validation of OIDC access tokens: [#3841](https://github.com/owncloud/ocis/issues/3841) + + Previously OIDC access tokes were only validated by requesting the userinfo from the IDP. It is + now possible to enable additional verification if the IDP issues access tokens in JWT format. + In that case the oCIS proxy service will now verify the signature of the token using the public + keys provided by jwks_uri endpoint of the IDP. It will also verify if the issuer claim (iss) + matches the expected values. + + The new validation is enabled by setting `PROXY_OIDC_ACCESS_TOKEN_VERIFY_METHOD` to + "jwt". Which is also the default. Setting it to "none" will disable the feature. + + https://github.com/owncloud/ocis/issues/3841 + https://github.com/owncloud/ocis/pull/4227 + +* Enhancement - Improve error log for "could not get user by claim" error: [#4227](https://github.com/owncloud/ocis/pull/4227) + + We've improved the error log for "could not get user by claim" error where previously only the + "nil" error has been logged. Now we're logging the message from the transport. + + https://github.com/owncloud/ocis/pull/4227 + * Enhancement - Introduce service registry cache: [#3833](https://github.com/owncloud/ocis/pull/3833) We've improved the service registry / service discovery by setting up registry caching (TTL @@ -879,6 +808,21 @@ The following sections list the changes for 2.0.0-beta.5. https://github.com/owncloud/ocis/issues/871 https://github.com/owncloud/ocis/pull/3935 +* Enhancement - Allow providing list of services NOT to start: [#4254](https://github.com/owncloud/ocis/pull/4254) + + Until now if one wanted to use a custom version of a service, one needed to provide + `OCIS_RUN_SERVICES` which is a list of all services to start. Now one can provide + `OCIS_EXCLUDE_RUN_SERVICES` which is a list of only services not to start + + https://github.com/owncloud/ocis/pull/4254 + +* Enhancement - Introduce insecure flag for smtp email notifications: [#4279](https://github.com/owncloud/ocis/pull/4279) + + We've introduced the `NOTIFICATIONS_SMTP_INSECURE` configuration option, that let's you + skip certificate verification for smtp email servers. + + https://github.com/owncloud/ocis/pull/4279 + * Enhancement - Optional events in graph service: [#55555](https://github.com/owncloud/ocis/pull/55555) We've changed the graph service so that you also can start it without any event bus. Therefore @@ -887,6 +831,21 @@ The following sections list the changes for 2.0.0-beta.5. https://github.com/owncloud/ocis/pull/55555 +* Enhancement - Fix behavior for foobar (in present tense): [#4346](https://github.com/owncloud/ocis/pull/4346) + + We've added the configuration option `PROXY_OIDC_REWRITE_WELLKNOWN` to rewrite the + `/.well-known/openid-configuration` endpoint. If active, it serves the + `/.well-known/openid-configuration` response of the original IDP configured in + `OCIS_OIDC_ISSUER` / `PROXY_OIDC_ISSUER`. This is needed so that the Desktop Client, + Android Client and iOS Client can discover the OIDC identity provider. + + Previously this rewrite needed to be performed with an external proxy as NGINX or Traefik if an + external IDP was used. + + https://github.com/owncloud/ocis/issues/2819 + https://github.com/owncloud/ocis/issues/3280 + https://github.com/owncloud/ocis/pull/4346 + * Enhancement - Add config option to provide TLS certificate: [#3818](https://github.com/owncloud/ocis/issues/3818) Added a config option to the graph service to provide a TLS certificate to be used to verify the @@ -988,6 +947,13 @@ The following sections list the changes for 2.0.0-beta.5. https://github.com/owncloud/ocis/pull/3626 +* Enhancement - Use storageID when requesting special items: [#4356](https://github.com/owncloud/ocis/pull/4356) + + We need to use the storageID when requesting the special items of a space to spare a registry + lookup and improve the performance + + https://github.com/owncloud/ocis/pull/4356 + * Enhancement - Add description tags to the thumbnails config structs: [#3752](https://github.com/owncloud/ocis/pull/3752) Added description tags to the config structs in the thumbnails service so they will be included @@ -1100,6 +1066,34 @@ The following sections list the changes for 2.0.0-beta.5. https://github.com/owncloud/ocis/pull/4025 https://github.com/owncloud/ocis/pull/4211 +* Enhancement - Update reva to v2.7.4: [#4294](https://github.com/owncloud/ocis/pull/4294) + + Updated reva to version 2.7.4 This update includes: + + * Bugfix [cs3org/reva#3141](https://github.com/cs3org/reva/pull/3141): Check ListGrants permission when listing shares + + Updated reva to version 2.7.3 This update includes: + + * Bugfix [cs3org/reva#3109](https://github.com/cs3org/reva/pull/3109): Bugfix missing check in MustCheckNodePermissions + * Bugfix [cs3org/reva#3086](https://github.com/cs3org/reva/pull/3086): Bugfix crash in ldap authprovider + * Bugfix [cs3org/reva#3094](https://github.com/cs3org/reva/pull/3094): Allow removing password from public links + * Bugfix [cs3org/reva#3096](https://github.com/cs3org/reva/pull/3096): Bugfix user filter + * Bugfix [cs3org/reva#3091](https://github.com/cs3org/reva/pull/3091): Project spaces need no real owner + * Bugfix [cs3org/reva#3088](https://github.com/cs3org/reva/pull/3088): Use correct sublogger + * Enhancement [cs3org/reva#3123](https://github.com/cs3org/reva/pull/3123): Allow stating links that have no permissions + * Enhancement [cs3org/reva#3087](https://github.com/cs3org/reva/pull/3087): Allow to set LDAP substring filter type + * Enhancement [cs3org/reva#3098](https://github.com/cs3org/reva/pull/3098): App provider http endpoint uses Form instead of Query + * Enhancement [cs3org/reva#3133](https://github.com/cs3org/reva/pull/3133): Admins can set quota on all spaces + * Enhancement [cs3org/reva#3117](https://github.com/cs3org/reva/pull/3117): Update go-ldap to v3.4.4 + * Enhancement [cs3org/reva#3095](https://github.com/cs3org/reva/pull/3095): Upload expiration and cleanup + + Https://github.com/owncloud/ocis/pull/4272 + https://github.com/cs3org/reva/pull/3096 https://github.com/cs3org/reva/pull/4315 + + https://github.com/owncloud/ocis/pull/4294 + https://github.com/owncloud/ocis/pull/4330 + https://github.com/owncloud/ocis/pull/4369 + * Enhancement - Update reva to version 2.4.1: [#3746](https://github.com/owncloud/ocis/pull/3746) Changelog for reva 2.4.1 (2022-05-24) ======================================= @@ -1373,6 +1367,64 @@ The following sections list the changes for 2.0.0-beta.5. https://github.com/owncloud/ocis/pull/4140 https://github.com/owncloud/web/releases/tag/v5.7.0-rc.4 +* Enhancement - Update ownCloud Web to v5.7.0-rc.8: [#4314](https://github.com/owncloud/ocis/pull/4314) + + Tags: web + + We updated ownCloud Web to v5.7.0-rc.9. Please refer to the changelog (linked) for details on + the web release. + + * Bugfix [owncloud/web#7080](https://github.com/owncloud/web/issues/7080): Add Droparea again + * Bugfix [owncloud/web#7357](https://github.com/owncloud/web/pull/7357): Batch deleting multiple files + * Bugfix [owncloud/web#7379](https://github.com/owncloud/web/pull/7379): Decline share not possible + * Bugfix [owncloud/web#7322](https://github.com/owncloud/web/pull/7322): Files pagination scroll to top + * Bugfix [owncloud/web#7348](https://github.com/owncloud/web/pull/7348): Left sidebar active navigation item has wrong cursor + * Bugfix [owncloud/web#7355](https://github.com/owncloud/web/pull/7355): Link indicator on "Shared via link"-page + * Bugfix [owncloud/web#7325](https://github.com/owncloud/web/pull/7325): Loading state in views + * Bugfix [owncloud/web#7344](https://github.com/owncloud/web/pull/7344): Missing file icon in details panel + * Bugfix [owncloud/web#7321](https://github.com/owncloud/web/pull/7321): Missing scroll bar in user management app + * Bugfix [owncloud/web#7334](https://github.com/owncloud/web/pull/7334): No redirect after disabling space + * Bugfix [owncloud/web#3071](https://github.com/owncloud/web/issues/3071): Don't leak oidc callback url into browser history + * Bugfix [owncloud/web#7379](https://github.com/owncloud/web/pull/7379): Open file on shared space resource not possible + * Bugfix [owncloud/web#7268](https://github.com/owncloud/web/issues/7268): Personal shares leaked into project space + * Bugfix [owncloud/web#7359](https://github.com/owncloud/web/pull/7359): Fix infinite loading spinner on invalid preview links + * Bugfix [owncloud/web#7272](https://github.com/owncloud/web/issues/7272): Print backend version + * Bugfix [owncloud/web#7424](https://github.com/owncloud/web/pull/7424): Quicklinks not shown + * Bugfix [owncloud/web#7379](https://github.com/owncloud/web/pull/7379): Rename shared space resource not possible + * Bugfix [owncloud/web#7210](https://github.com/owncloud/web/pull/7210): Repair navigation highlighter + * Bugfix [owncloud/web#7393](https://github.com/owncloud/web/pull/7393): Selected item bottom glue + * Bugfix [owncloud/web#7308](https://github.com/owncloud/web/pull/7308): "Shared with others" and "Shared via Link" resource links not working + * Bugfix [owncloud/web#7400](https://github.com/owncloud/web/issues/7400): Respect space quota permission + * Bugfix [owncloud/web#7349](https://github.com/owncloud/web/pull/7349): Missing quick actions in spaces file list + * Bugfix [owncloud/web#7396](https://github.com/owncloud/web/pull/7396): Add storage ID when navigating to a shared parent directory + * Bugfix [owncloud/web#7394](https://github.com/owncloud/web/pull/7394): Suppress active panel error log + * Bugfix [owncloud/web#7038](https://github.com/owncloud/web/issues/7038): File list render performance + * Bugfix [owncloud/web#7240](https://github.com/owncloud/web/issues/7240): Access token renewal during upload + * Bugfix [owncloud/web#7376](https://github.com/owncloud/web/pull/7376): Tooltips not shown on disabled create and upload button + * Bugfix [owncloud/web#7297](https://github.com/owncloud/web/pull/7297): Upload overlay progress bar spacing + * Bugfix [owncloud/web#7332](https://github.com/owncloud/web/pull/7332): Users list not loading if user has no role + * Bugfix [owncloud/web#7313](https://github.com/owncloud/web/pull/7313): Versions of shared files not visible + * Enhancement [owncloud/web#7404](https://github.com/owncloud/web/pull/7404): Adjust helper texts + * Enhancement [owncloud/web#7350](https://github.com/owncloud/web/pull/7350): Change file loading mechanism in `preview` app + * Enhancement [owncloud/web#7356](https://github.com/owncloud/web/pull/7356): Declined shares are now easily accessible + * Enhancement [owncloud/web#7365](https://github.com/owncloud/web/pull/7365): Drop menu styling in right sidebar + * Enhancement [owncloud/web#7252](https://github.com/owncloud/web/pull/7252): Redesign shared with list + * Enhancement [owncloud/web#7371](https://github.com/owncloud/web/pull/7371): Use fixed width for the right sidebar + * Enhancement [owncloud/web#7267](https://github.com/owncloud/web/pull/7267): Search all files announce limit + * Enhancement [owncloud/web#7364](https://github.com/owncloud/web/pull/7364): Sharing panel show label instead of description for links + * Enhancement [owncloud/web#7355](https://github.com/owncloud/web/pull/7355): Update ODS to v14.0.0-alpha.12 + * Enhancement [owncloud/web#7375](https://github.com/owncloud/web/pull/7375): User management app saved dialog + + https://github.com/owncloud/ocis/pull/4314 + https://github.com/owncloud/web/releases/tag/v5.7.0-rc.8 + +* Enhancement - Expand personal drive on the graph user: [#4357](https://github.com/owncloud/ocis/pull/4357) + + We can now list the personal drive on the users endpoint via the graph API. A user can add an + `$expand=drive` query to list the personal drive of the requested user. + + https://github.com/owncloud/ocis/pull/4357 + * Enhancement - Add descriptions to webdav configuration: [#3755](https://github.com/owncloud/ocis/pull/3755) Added descriptions to webdav config structs to include them in the config documentation. @@ -1388,7 +1440,7 @@ The following sections list the changes for 2.0.0-beta.5. The following sections list the changes for 1.20.0. -[1.20.0]: https://github.com/owncloud/ocis/compare/v1.19.0...v1.20.0 +[1.20.0]: https://github.com/owncloud/ocis/compare/v1.19.1...v1.20.0 ## Summary @@ -1556,11 +1608,28 @@ The following sections list the changes for 1.20.0. Group member remove https://github.com/owncloud/ocis/pull/3467 +# Changelog for [1.19.1] (2022-03-29) + +The following sections list the changes for 1.19.1. + +[1.19.1]: https://github.com/owncloud/ocis/compare/v1.19.0...v1.19.1 + +## Summary + +* Bugfix - Return correct special item urls: [#3419](https://github.com/owncloud/ocis/pull/3419) + +## Details + +* Bugfix - Return correct special item urls: [#3419](https://github.com/owncloud/ocis/pull/3419) + + URLs for Special items (space image, readme) were broken. + + https://github.com/owncloud/ocis/pull/3419 # Changelog for [1.19.0] (2022-03-29) The following sections list the changes for 1.19.0. -[1.19.0]: https://github.com/owncloud/ocis/compare/v1.19.1...v1.19.0 +[1.19.0]: https://github.com/owncloud/ocis/compare/v1.18.0...v1.19.0 ## Summary @@ -1729,23 +1798,6 @@ The following sections list the changes for 1.19.0. https://github.com/owncloud/ocis/pull/3291 https://github.com/owncloud/ocis/pull/3375 https://github.com/owncloud/web/releases/tag/v5.3.0 -# Changelog for [1.19.1] (2022-03-29) - -The following sections list the changes for 1.19.1. - -[1.19.1]: https://github.com/owncloud/ocis/compare/v1.18.0...v1.19.1 - -## Summary - -* Bugfix - Return correct special item urls: [#3419](https://github.com/owncloud/ocis/pull/3419) - -## Details - -* Bugfix - Return correct special item urls: [#3419](https://github.com/owncloud/ocis/pull/3419) - - URLs for Special items (space image, readme) were broken. - - https://github.com/owncloud/ocis/pull/3419 # Changelog for [1.18.0] (2022-03-03) The following sections list the changes for 1.18.0. diff --git a/Makefile b/Makefile index 0c29bbe8365..49d9ac89512 100644 --- a/Makefile +++ b/Makefile @@ -185,6 +185,18 @@ protobuf: echo -n "% protobuf $$mod: "; $(MAKE) --no-print-directory -C $$mod protobuf || exit 1; \ done +.PHONY: golangci-lint +golangci-lint: + @for mod in $(OCIS_MODULES); do \ + $(MAKE) --no-print-directory -C $$mod golangci-lint; \ + done + +.PHONY: golangci-lint-fix +golangci-lint-fix: + @for mod in $(OCIS_MODULES); do \ + $(MAKE) --no-print-directory -C $$mod golangci-lint-fix; \ + done + .PHONY: bingo-update bingo-update: $(BINGO) $(BINGO) get -l -u diff --git a/changelog/2.0.0_2022-07-19/add-aliaslink-capability.md b/changelog/2.0.0_2022-08-11/add-aliaslink-capability.md similarity index 100% rename from changelog/2.0.0_2022-07-19/add-aliaslink-capability.md rename to changelog/2.0.0_2022-08-11/add-aliaslink-capability.md diff --git a/changelog/unreleased/add-drives-endpoint-and-userfilter.md b/changelog/2.0.0_2022-08-11/add-drives-endpoint-and-userfilter.md similarity index 100% rename from changelog/unreleased/add-drives-endpoint-and-userfilter.md rename to changelog/2.0.0_2022-08-11/add-drives-endpoint-and-userfilter.md diff --git a/changelog/2.0.0_2022-07-19/add-resharing-env.md b/changelog/2.0.0_2022-08-11/add-resharing-env.md similarity index 100% rename from changelog/2.0.0_2022-07-19/add-resharing-env.md rename to changelog/2.0.0_2022-08-11/add-resharing-env.md diff --git a/changelog/2.0.0_2022-07-19/add-total-to-search-results.md b/changelog/2.0.0_2022-08-11/add-total-to-search-results.md similarity index 100% rename from changelog/2.0.0_2022-07-19/add-total-to-search-results.md rename to changelog/2.0.0_2022-08-11/add-total-to-search-results.md diff --git a/changelog/2.0.0_2022-07-19/align-service-naming.md b/changelog/2.0.0_2022-08-11/align-service-naming.md similarity index 100% rename from changelog/2.0.0_2022-07-19/align-service-naming.md rename to changelog/2.0.0_2022-08-11/align-service-naming.md diff --git a/changelog/2.0.0_2022-07-19/audit-service.md b/changelog/2.0.0_2022-08-11/audit-service.md similarity index 100% rename from changelog/2.0.0_2022-07-19/audit-service.md rename to changelog/2.0.0_2022-08-11/audit-service.md diff --git a/changelog/2.0.0_2022-07-19/bump-libregraph-idm.md b/changelog/2.0.0_2022-08-11/bump-libregraph-idm.md similarity index 100% rename from changelog/2.0.0_2022-07-19/bump-libregraph-idm.md rename to changelog/2.0.0_2022-08-11/bump-libregraph-idm.md diff --git a/changelog/2.0.0_2022-07-19/bump-ocis-package-v2.md b/changelog/2.0.0_2022-08-11/bump-ocis-package-v2.md similarity index 100% rename from changelog/2.0.0_2022-07-19/bump-ocis-package-v2.md rename to changelog/2.0.0_2022-08-11/bump-ocis-package-v2.md diff --git a/changelog/2.0.0_2022-07-19/change-load-config-from-only-one-dir.md b/changelog/2.0.0_2022-08-11/change-load-config-from-only-one-dir.md similarity index 100% rename from changelog/2.0.0_2022-07-19/change-load-config-from-only-one-dir.md rename to changelog/2.0.0_2022-08-11/change-load-config-from-only-one-dir.md diff --git a/changelog/2.0.0_2022-07-19/change-ocis-docker-volume-permissions.md b/changelog/2.0.0_2022-08-11/change-ocis-docker-volume-permissions.md similarity index 100% rename from changelog/2.0.0_2022-07-19/change-ocis-docker-volume-permissions.md rename to changelog/2.0.0_2022-08-11/change-ocis-docker-volume-permissions.md diff --git a/changelog/2.0.0_2022-07-19/change-ocis-init.md b/changelog/2.0.0_2022-08-11/change-ocis-init.md similarity index 100% rename from changelog/2.0.0_2022-07-19/change-ocis-init.md rename to changelog/2.0.0_2022-08-11/change-ocis-init.md diff --git a/changelog/2.0.0_2022-07-19/change-remove-runtime-kill-run-commands.md b/changelog/2.0.0_2022-08-11/change-remove-runtime-kill-run-commands.md similarity index 100% rename from changelog/2.0.0_2022-07-19/change-remove-runtime-kill-run-commands.md rename to changelog/2.0.0_2022-08-11/change-remove-runtime-kill-run-commands.md diff --git a/changelog/2.0.0_2022-07-19/container-created-audit.md b/changelog/2.0.0_2022-08-11/container-created-audit.md similarity index 100% rename from changelog/2.0.0_2022-07-19/container-created-audit.md rename to changelog/2.0.0_2022-08-11/container-created-audit.md diff --git a/changelog/2.0.0_2022-07-19/default-role-assignments.md b/changelog/2.0.0_2022-08-11/default-role-assignments.md similarity index 100% rename from changelog/2.0.0_2022-07-19/default-role-assignments.md rename to changelog/2.0.0_2022-08-11/default-role-assignments.md diff --git a/changelog/2.0.0_2022-07-19/deleteSpacePermissions.md b/changelog/2.0.0_2022-08-11/deleteSpacePermissions.md similarity index 100% rename from changelog/2.0.0_2022-07-19/deleteSpacePermissions.md rename to changelog/2.0.0_2022-08-11/deleteSpacePermissions.md diff --git a/changelog/unreleased/enhancement-access-token-validation.md b/changelog/2.0.0_2022-08-11/enhancement-access-token-validation.md similarity index 100% rename from changelog/unreleased/enhancement-access-token-validation.md rename to changelog/2.0.0_2022-08-11/enhancement-access-token-validation.md diff --git a/changelog/unreleased/enhancement-error-by-claim.md b/changelog/2.0.0_2022-08-11/enhancement-error-by-claim.md similarity index 100% rename from changelog/unreleased/enhancement-error-by-claim.md rename to changelog/2.0.0_2022-08-11/enhancement-error-by-claim.md diff --git a/changelog/2.0.0_2022-07-19/enhancement-registry-cache.md b/changelog/2.0.0_2022-08-11/enhancement-registry-cache.md similarity index 100% rename from changelog/2.0.0_2022-07-19/enhancement-registry-cache.md rename to changelog/2.0.0_2022-08-11/enhancement-registry-cache.md diff --git a/changelog/2.0.0_2022-07-19/enhancement-user-autoprovision.md b/changelog/2.0.0_2022-08-11/enhancement-user-autoprovision.md similarity index 100% rename from changelog/2.0.0_2022-07-19/enhancement-user-autoprovision.md rename to changelog/2.0.0_2022-08-11/enhancement-user-autoprovision.md diff --git a/changelog/2.0.0_2022-07-19/example-deployments.md b/changelog/2.0.0_2022-08-11/example-deployments.md similarity index 100% rename from changelog/2.0.0_2022-07-19/example-deployments.md rename to changelog/2.0.0_2022-08-11/example-deployments.md diff --git a/changelog/unreleased/exclude-services-option.md b/changelog/2.0.0_2022-08-11/exclude-services-option.md similarity index 100% rename from changelog/unreleased/exclude-services-option.md rename to changelog/2.0.0_2022-08-11/exclude-services-option.md diff --git a/changelog/unreleased/feature-mail-insecure.md b/changelog/2.0.0_2022-08-11/feature-mail-insecure.md similarity index 100% rename from changelog/unreleased/feature-mail-insecure.md rename to changelog/2.0.0_2022-08-11/feature-mail-insecure.md diff --git a/changelog/2.0.0_2022-07-19/feature-optional-events-in-graph-service.md b/changelog/2.0.0_2022-08-11/feature-optional-events-in-graph-service.md similarity index 100% rename from changelog/2.0.0_2022-07-19/feature-optional-events-in-graph-service.md rename to changelog/2.0.0_2022-08-11/feature-optional-events-in-graph-service.md diff --git a/changelog/unreleased/feature-rewrite-well-known-openid-configuration.md b/changelog/2.0.0_2022-08-11/feature-rewrite-well-known-openid-configuration.md similarity index 100% rename from changelog/unreleased/feature-rewrite-well-known-openid-configuration.md rename to changelog/2.0.0_2022-08-11/feature-rewrite-well-known-openid-configuration.md diff --git a/changelog/2.0.0_2022-07-19/fix-align-login-attr.md b/changelog/2.0.0_2022-08-11/fix-align-login-attr.md similarity index 100% rename from changelog/2.0.0_2022-07-19/fix-align-login-attr.md rename to changelog/2.0.0_2022-08-11/fix-align-login-attr.md diff --git a/changelog/2.0.0_2022-07-19/fix-allow-empty-environment-variables b/changelog/2.0.0_2022-08-11/fix-allow-empty-environment-variables similarity index 100% rename from changelog/2.0.0_2022-07-19/fix-allow-empty-environment-variables rename to changelog/2.0.0_2022-08-11/fix-allow-empty-environment-variables diff --git a/changelog/2.0.0_2022-07-19/fix-app-provider-unused-transfer-secret.md b/changelog/2.0.0_2022-08-11/fix-app-provider-unused-transfer-secret.md similarity index 100% rename from changelog/2.0.0_2022-07-19/fix-app-provider-unused-transfer-secret.md rename to changelog/2.0.0_2022-08-11/fix-app-provider-unused-transfer-secret.md diff --git a/changelog/2.0.0_2022-07-19/fix-configure-idp-secrets-env.md b/changelog/2.0.0_2022-08-11/fix-configure-idp-secrets-env.md similarity index 100% rename from changelog/2.0.0_2022-07-19/fix-configure-idp-secrets-env.md rename to changelog/2.0.0_2022-08-11/fix-configure-idp-secrets-env.md diff --git a/changelog/2.0.0_2022-07-19/fix-csp-silent-refresh.md b/changelog/2.0.0_2022-08-11/fix-csp-silent-refresh.md similarity index 100% rename from changelog/2.0.0_2022-07-19/fix-csp-silent-refresh.md rename to changelog/2.0.0_2022-08-11/fix-csp-silent-refresh.md diff --git a/changelog/2.0.0_2022-07-19/fix-debug-config-enable-by-default.md b/changelog/2.0.0_2022-08-11/fix-debug-config-enable-by-default.md similarity index 100% rename from changelog/2.0.0_2022-07-19/fix-debug-config-enable-by-default.md rename to changelog/2.0.0_2022-08-11/fix-debug-config-enable-by-default.md diff --git a/changelog/2.0.0_2022-07-19/fix-default-role-assign.md b/changelog/2.0.0_2022-08-11/fix-default-role-assign.md similarity index 100% rename from changelog/2.0.0_2022-07-19/fix-default-role-assign.md rename to changelog/2.0.0_2022-08-11/fix-default-role-assign.md diff --git a/changelog/2.0.0_2022-07-19/fix-index-integrity.md b/changelog/2.0.0_2022-08-11/fix-index-integrity.md similarity index 100% rename from changelog/2.0.0_2022-07-19/fix-index-integrity.md rename to changelog/2.0.0_2022-08-11/fix-index-integrity.md diff --git a/changelog/2.0.0_2022-07-19/fix-ldap-filter-envvar.md b/changelog/2.0.0_2022-08-11/fix-ldap-filter-envvar.md similarity index 100% rename from changelog/2.0.0_2022-07-19/fix-ldap-filter-envvar.md rename to changelog/2.0.0_2022-08-11/fix-ldap-filter-envvar.md diff --git a/changelog/2.0.0_2022-07-19/fix-ldap-insecure-options.md b/changelog/2.0.0_2022-08-11/fix-ldap-insecure-options.md similarity index 100% rename from changelog/2.0.0_2022-07-19/fix-ldap-insecure-options.md rename to changelog/2.0.0_2022-08-11/fix-ldap-insecure-options.md diff --git a/changelog/unreleased/fix-ldap-invalid-users-groups.md b/changelog/2.0.0_2022-08-11/fix-ldap-invalid-users-groups.md similarity index 100% rename from changelog/unreleased/fix-ldap-invalid-users-groups.md rename to changelog/2.0.0_2022-08-11/fix-ldap-invalid-users-groups.md diff --git a/changelog/2.0.0_2022-07-19/fix-logging-levels.md b/changelog/2.0.0_2022-08-11/fix-logging-levels.md similarity index 100% rename from changelog/2.0.0_2022-07-19/fix-logging-levels.md rename to changelog/2.0.0_2022-08-11/fix-logging-levels.md diff --git a/changelog/2.0.0_2022-07-19/fix-ocis-run-services.md b/changelog/2.0.0_2022-08-11/fix-ocis-run-services.md similarity index 100% rename from changelog/2.0.0_2022-07-19/fix-ocis-run-services.md rename to changelog/2.0.0_2022-08-11/fix-ocis-run-services.md diff --git a/changelog/2.0.0_2022-07-19/fix-public-link-defaultname-capability b/changelog/2.0.0_2022-08-11/fix-public-link-defaultname-capability similarity index 100% rename from changelog/2.0.0_2022-07-19/fix-public-link-defaultname-capability rename to changelog/2.0.0_2022-08-11/fix-public-link-defaultname-capability diff --git a/changelog/2.0.0_2022-07-19/fix-remove-legacy-accounts-routes.md b/changelog/2.0.0_2022-08-11/fix-remove-legacy-accounts-routes.md similarity index 100% rename from changelog/2.0.0_2022-07-19/fix-remove-legacy-accounts-routes.md rename to changelog/2.0.0_2022-08-11/fix-remove-legacy-accounts-routes.md diff --git a/changelog/2.0.0_2022-07-19/fix-remove-unused-GRAPH_SPACES_INSECURE.md b/changelog/2.0.0_2022-08-11/fix-remove-unused-GRAPH_SPACES_INSECURE.md similarity index 100% rename from changelog/2.0.0_2022-07-19/fix-remove-unused-GRAPH_SPACES_INSECURE.md rename to changelog/2.0.0_2022-08-11/fix-remove-unused-GRAPH_SPACES_INSECURE.md diff --git a/changelog/2.0.0_2022-07-19/fix-remove-unused-config-options.md b/changelog/2.0.0_2022-08-11/fix-remove-unused-config-options.md similarity index 100% rename from changelog/2.0.0_2022-07-19/fix-remove-unused-config-options.md rename to changelog/2.0.0_2022-08-11/fix-remove-unused-config-options.md diff --git a/changelog/2.0.0_2022-07-19/fix-remove-unused-ocs-backend-config.md b/changelog/2.0.0_2022-08-11/fix-remove-unused-ocs-backend-config.md similarity index 100% rename from changelog/2.0.0_2022-07-19/fix-remove-unused-ocs-backend-config.md rename to changelog/2.0.0_2022-08-11/fix-remove-unused-ocs-backend-config.md diff --git a/changelog/2.0.0_2022-07-19/fix-remove-unused-ocs-storage-config.md b/changelog/2.0.0_2022-08-11/fix-remove-unused-ocs-storage-config.md similarity index 100% rename from changelog/2.0.0_2022-07-19/fix-remove-unused-ocs-storage-config.md rename to changelog/2.0.0_2022-08-11/fix-remove-unused-ocs-storage-config.md diff --git a/changelog/2.0.0_2022-07-19/fix-search-command-server-command.md b/changelog/2.0.0_2022-08-11/fix-search-command-server-command.md similarity index 100% rename from changelog/2.0.0_2022-07-19/fix-search-command-server-command.md rename to changelog/2.0.0_2022-08-11/fix-search-command-server-command.md diff --git a/changelog/2.0.0_2022-07-19/fix-search-grpc-addr-env.md b/changelog/2.0.0_2022-08-11/fix-search-grpc-addr-env.md similarity index 100% rename from changelog/2.0.0_2022-07-19/fix-search-grpc-addr-env.md rename to changelog/2.0.0_2022-08-11/fix-search-grpc-addr-env.md diff --git a/changelog/unreleased/fix-search-in-received-shares.md b/changelog/2.0.0_2022-08-11/fix-search-in-received-shares.md similarity index 100% rename from changelog/unreleased/fix-search-in-received-shares.md rename to changelog/2.0.0_2022-08-11/fix-search-in-received-shares.md diff --git a/changelog/2.0.0_2022-07-19/fix-sensitive-values-proxy-debug-config.md b/changelog/2.0.0_2022-08-11/fix-sensitive-values-proxy-debug-config.md similarity index 100% rename from changelog/2.0.0_2022-07-19/fix-sensitive-values-proxy-debug-config.md rename to changelog/2.0.0_2022-08-11/fix-sensitive-values-proxy-debug-config.md diff --git a/changelog/2.0.0_2022-07-19/fix-settings-idm-adminuserid.md b/changelog/2.0.0_2022-08-11/fix-settings-idm-adminuserid.md similarity index 100% rename from changelog/2.0.0_2022-07-19/fix-settings-idm-adminuserid.md rename to changelog/2.0.0_2022-08-11/fix-settings-idm-adminuserid.md diff --git a/changelog/unreleased/fix-sharee-substring-search.md b/changelog/2.0.0_2022-08-11/fix-sharee-substring-search.md similarity index 100% rename from changelog/unreleased/fix-sharee-substring-search.md rename to changelog/2.0.0_2022-08-11/fix-sharee-substring-search.md diff --git a/changelog/2.0.0_2022-07-19/fix-skip-validate-for-non-fullstack.md b/changelog/2.0.0_2022-08-11/fix-skip-validate-for-non-fullstack.md similarity index 100% rename from changelog/2.0.0_2022-07-19/fix-skip-validate-for-non-fullstack.md rename to changelog/2.0.0_2022-08-11/fix-skip-validate-for-non-fullstack.md diff --git a/changelog/2.0.0_2022-07-19/fix-startup-error-logging.md b/changelog/2.0.0_2022-08-11/fix-startup-error-logging.md similarity index 100% rename from changelog/2.0.0_2022-07-19/fix-startup-error-logging.md rename to changelog/2.0.0_2022-08-11/fix-startup-error-logging.md diff --git a/changelog/2.0.0_2022-07-19/fix-storage-users-config.md b/changelog/2.0.0_2022-08-11/fix-storage-users-config.md similarity index 100% rename from changelog/2.0.0_2022-07-19/fix-storage-users-config.md rename to changelog/2.0.0_2022-08-11/fix-storage-users-config.md diff --git a/changelog/2.0.0_2022-07-19/fix-thumbnails-dav.md b/changelog/2.0.0_2022-08-11/fix-thumbnails-dav.md similarity index 100% rename from changelog/2.0.0_2022-07-19/fix-thumbnails-dav.md rename to changelog/2.0.0_2022-08-11/fix-thumbnails-dav.md diff --git a/changelog/unreleased/fix-unrestricted-quota.md b/changelog/2.0.0_2022-08-11/fix-unrestricted-quota.md similarity index 100% rename from changelog/unreleased/fix-unrestricted-quota.md rename to changelog/2.0.0_2022-08-11/fix-unrestricted-quota.md diff --git a/changelog/2.0.0_2022-07-19/fix-user-autoprovision.md b/changelog/2.0.0_2022-08-11/fix-user-autoprovision.md similarity index 100% rename from changelog/2.0.0_2022-07-19/fix-user-autoprovision.md rename to changelog/2.0.0_2022-08-11/fix-user-autoprovision.md diff --git a/changelog/2.0.0_2022-07-19/fix-version-info b/changelog/2.0.0_2022-08-11/fix-version-info similarity index 100% rename from changelog/2.0.0_2022-07-19/fix-version-info rename to changelog/2.0.0_2022-08-11/fix-version-info diff --git a/changelog/2.0.0_2022-07-19/fix-version.md b/changelog/2.0.0_2022-08-11/fix-version.md similarity index 100% rename from changelog/2.0.0_2022-07-19/fix-version.md rename to changelog/2.0.0_2022-08-11/fix-version.md diff --git a/changelog/2.0.0_2022-07-19/glauth-accounts-rm.md b/changelog/2.0.0_2022-08-11/glauth-accounts-rm.md similarity index 100% rename from changelog/2.0.0_2022-07-19/glauth-accounts-rm.md rename to changelog/2.0.0_2022-08-11/glauth-accounts-rm.md diff --git a/changelog/2.0.0_2022-07-19/graph-cacert.md b/changelog/2.0.0_2022-08-11/graph-cacert.md similarity index 100% rename from changelog/2.0.0_2022-07-19/graph-cacert.md rename to changelog/2.0.0_2022-08-11/graph-cacert.md diff --git a/changelog/2.0.0_2022-07-19/graph-explorer-env-doc.md b/changelog/2.0.0_2022-08-11/graph-explorer-env-doc.md similarity index 100% rename from changelog/2.0.0_2022-07-19/graph-explorer-env-doc.md rename to changelog/2.0.0_2022-08-11/graph-explorer-env-doc.md diff --git a/changelog/2.0.0_2022-07-19/graph-me-changepw.md b/changelog/2.0.0_2022-08-11/graph-me-changepw.md similarity index 100% rename from changelog/2.0.0_2022-07-19/graph-me-changepw.md rename to changelog/2.0.0_2022-08-11/graph-me-changepw.md diff --git a/changelog/2.0.0_2022-07-19/graph-me-drives.md b/changelog/2.0.0_2022-08-11/graph-me-drives.md similarity index 100% rename from changelog/2.0.0_2022-07-19/graph-me-drives.md rename to changelog/2.0.0_2022-08-11/graph-me-drives.md diff --git a/changelog/2.0.0_2022-07-19/graph-webdav-url.md b/changelog/2.0.0_2022-08-11/graph-webdav-url.md similarity index 100% rename from changelog/2.0.0_2022-07-19/graph-webdav-url.md rename to changelog/2.0.0_2022-08-11/graph-webdav-url.md diff --git a/changelog/2.0.0_2022-07-19/idp-cert-wait.md b/changelog/2.0.0_2022-08-11/idp-cert-wait.md similarity index 100% rename from changelog/2.0.0_2022-07-19/idp-cert-wait.md rename to changelog/2.0.0_2022-08-11/idp-cert-wait.md diff --git a/changelog/2.0.0_2022-07-19/idp-default-files.md b/changelog/2.0.0_2022-08-11/idp-default-files.md similarity index 100% rename from changelog/2.0.0_2022-07-19/idp-default-files.md rename to changelog/2.0.0_2022-08-11/idp-default-files.md diff --git a/changelog/2.0.0_2022-07-19/idp-ui-update.md b/changelog/2.0.0_2022-08-11/idp-ui-update.md similarity index 100% rename from changelog/2.0.0_2022-07-19/idp-ui-update.md rename to changelog/2.0.0_2022-08-11/idp-ui-update.md diff --git a/changelog/2.0.0_2022-07-19/improve-graph.md b/changelog/2.0.0_2022-08-11/improve-graph.md similarity index 100% rename from changelog/2.0.0_2022-07-19/improve-graph.md rename to changelog/2.0.0_2022-08-11/improve-graph.md diff --git a/changelog/2.0.0_2022-07-19/ldap-escape-dn.md b/changelog/2.0.0_2022-08-11/ldap-escape-dn.md similarity index 100% rename from changelog/2.0.0_2022-07-19/ldap-escape-dn.md rename to changelog/2.0.0_2022-08-11/ldap-escape-dn.md diff --git a/changelog/2.0.0_2022-07-19/libregraph-idm-switch.md b/changelog/2.0.0_2022-08-11/libregraph-idm-switch.md similarity index 100% rename from changelog/2.0.0_2022-07-19/libregraph-idm-switch.md rename to changelog/2.0.0_2022-08-11/libregraph-idm-switch.md diff --git a/changelog/2.0.0_2022-07-19/make-idp-only-wait-for-certs-when-using-ldap.md b/changelog/2.0.0_2022-08-11/make-idp-only-wait-for-certs-when-using-ldap.md similarity index 100% rename from changelog/2.0.0_2022-07-19/make-idp-only-wait-for-certs-when-using-ldap.md rename to changelog/2.0.0_2022-08-11/make-idp-only-wait-for-certs-when-using-ldap.md diff --git a/changelog/2.0.0_2022-07-19/make-ocdav-service-behave.md b/changelog/2.0.0_2022-08-11/make-ocdav-service-behave.md similarity index 100% rename from changelog/2.0.0_2022-07-19/make-ocdav-service-behave.md rename to changelog/2.0.0_2022-08-11/make-ocdav-service-behave.md diff --git a/changelog/2.0.0_2022-07-19/metadata-gateway.md b/changelog/2.0.0_2022-08-11/metadata-gateway.md similarity index 100% rename from changelog/2.0.0_2022-07-19/metadata-gateway.md rename to changelog/2.0.0_2022-08-11/metadata-gateway.md diff --git a/changelog/2.0.0_2022-07-19/metadatauserid-systemuserid.md b/changelog/2.0.0_2022-08-11/metadatauserid-systemuserid.md similarity index 100% rename from changelog/2.0.0_2022-07-19/metadatauserid-systemuserid.md rename to changelog/2.0.0_2022-08-11/metadatauserid-systemuserid.md diff --git a/changelog/2.0.0_2022-07-19/migrate-command.md b/changelog/2.0.0_2022-08-11/migrate-command.md similarity index 100% rename from changelog/2.0.0_2022-07-19/migrate-command.md rename to changelog/2.0.0_2022-08-11/migrate-command.md diff --git a/changelog/2.0.0_2022-07-19/new-space-id-functions.md b/changelog/2.0.0_2022-08-11/new-space-id-functions.md similarity index 100% rename from changelog/2.0.0_2022-07-19/new-space-id-functions.md rename to changelog/2.0.0_2022-08-11/new-space-id-functions.md diff --git a/changelog/2.0.0_2022-07-19/ocs-cs3-fatal.md b/changelog/2.0.0_2022-08-11/ocs-cs3-fatal.md similarity index 100% rename from changelog/2.0.0_2022-07-19/ocs-cs3-fatal.md rename to changelog/2.0.0_2022-08-11/ocs-cs3-fatal.md diff --git a/changelog/2.0.0_2022-07-19/ocs-version-product-field.md b/changelog/2.0.0_2022-08-11/ocs-version-product-field.md similarity index 100% rename from changelog/2.0.0_2022-07-19/ocs-version-product-field.md rename to changelog/2.0.0_2022-08-11/ocs-version-product-field.md diff --git a/changelog/2.0.0_2022-07-19/polish-search.md b/changelog/2.0.0_2022-08-11/polish-search.md similarity index 100% rename from changelog/2.0.0_2022-07-19/polish-search.md rename to changelog/2.0.0_2022-08-11/polish-search.md diff --git a/changelog/2.0.0_2022-07-19/prevent-access-to-disabled-space.md b/changelog/2.0.0_2022-08-11/prevent-access-to-disabled-space.md similarity index 100% rename from changelog/2.0.0_2022-07-19/prevent-access-to-disabled-space.md rename to changelog/2.0.0_2022-08-11/prevent-access-to-disabled-space.md diff --git a/changelog/2.0.0_2022-07-19/refactor-extensions-to-services.md b/changelog/2.0.0_2022-08-11/refactor-extensions-to-services.md similarity index 100% rename from changelog/2.0.0_2022-07-19/refactor-extensions-to-services.md rename to changelog/2.0.0_2022-08-11/refactor-extensions-to-services.md diff --git a/changelog/2.0.0_2022-07-19/resharing.md b/changelog/2.0.0_2022-08-11/resharing.md similarity index 100% rename from changelog/2.0.0_2022-07-19/resharing.md rename to changelog/2.0.0_2022-08-11/resharing.md diff --git a/changelog/2.0.0_2022-07-19/save-katherine.md b/changelog/2.0.0_2022-08-11/save-katherine.md similarity index 100% rename from changelog/2.0.0_2022-07-19/save-katherine.md rename to changelog/2.0.0_2022-08-11/save-katherine.md diff --git a/changelog/2.0.0_2022-07-19/search-extension.md b/changelog/2.0.0_2022-08-11/search-extension.md similarity index 100% rename from changelog/2.0.0_2022-07-19/search-extension.md rename to changelog/2.0.0_2022-08-11/search-extension.md diff --git a/changelog/2.0.0_2022-07-19/serviceUser-systemUser.md b/changelog/2.0.0_2022-08-11/serviceUser-systemUser.md similarity index 100% rename from changelog/2.0.0_2022-07-19/serviceUser-systemUser.md rename to changelog/2.0.0_2022-08-11/serviceUser-systemUser.md diff --git a/changelog/2.0.0_2022-07-19/share-jail-fixes.md b/changelog/2.0.0_2022-08-11/share-jail-fixes.md similarity index 100% rename from changelog/2.0.0_2022-07-19/share-jail-fixes.md rename to changelog/2.0.0_2022-08-11/share-jail-fixes.md diff --git a/changelog/2.0.0_2022-07-19/single-file-edit.md b/changelog/2.0.0_2022-08-11/single-file-edit.md similarity index 100% rename from changelog/2.0.0_2022-07-19/single-file-edit.md rename to changelog/2.0.0_2022-08-11/single-file-edit.md diff --git a/changelog/2.0.0_2022-07-19/space-id.md b/changelog/2.0.0_2022-08-11/space-id.md similarity index 100% rename from changelog/2.0.0_2022-07-19/space-id.md rename to changelog/2.0.0_2022-08-11/space-id.md diff --git a/changelog/unreleased/space-owner.md b/changelog/2.0.0_2022-08-11/space-owner.md similarity index 100% rename from changelog/unreleased/space-owner.md rename to changelog/2.0.0_2022-08-11/space-owner.md diff --git a/changelog/2.0.0_2022-07-19/spaces-capabilities.md b/changelog/2.0.0_2022-08-11/spaces-capabilities.md similarity index 100% rename from changelog/2.0.0_2022-07-19/spaces-capabilities.md rename to changelog/2.0.0_2022-08-11/spaces-capabilities.md diff --git a/changelog/unreleased/special-items-improvements.md b/changelog/2.0.0_2022-08-11/special-items-improvements.md similarity index 100% rename from changelog/unreleased/special-items-improvements.md rename to changelog/2.0.0_2022-08-11/special-items-improvements.md diff --git a/changelog/2.0.0_2022-07-19/split-machineauth-and-systemuserauth.md b/changelog/2.0.0_2022-08-11/split-machineauth-and-systemuserauth.md similarity index 100% rename from changelog/2.0.0_2022-07-19/split-machineauth-and-systemuserauth.md rename to changelog/2.0.0_2022-08-11/split-machineauth-and-systemuserauth.md diff --git a/changelog/2.0.0_2022-07-19/thumbnails-env-doc.md b/changelog/2.0.0_2022-08-11/thumbnails-env-doc.md similarity index 100% rename from changelog/2.0.0_2022-07-19/thumbnails-env-doc.md rename to changelog/2.0.0_2022-08-11/thumbnails-env-doc.md diff --git a/changelog/2.0.0_2022-07-19/thumbnails-log.md b/changelog/2.0.0_2022-08-11/thumbnails-log.md similarity index 100% rename from changelog/2.0.0_2022-07-19/thumbnails-log.md rename to changelog/2.0.0_2022-08-11/thumbnails-log.md diff --git a/changelog/2.0.0_2022-07-19/update-linkshare-capabilities.md b/changelog/2.0.0_2022-08-11/update-linkshare-capabilities.md similarity index 100% rename from changelog/2.0.0_2022-07-19/update-linkshare-capabilities.md rename to changelog/2.0.0_2022-08-11/update-linkshare-capabilities.md diff --git a/changelog/2.0.0_2022-07-19/update-reva-beta.4.md b/changelog/2.0.0_2022-08-11/update-reva-beta.4.md similarity index 100% rename from changelog/2.0.0_2022-07-19/update-reva-beta.4.md rename to changelog/2.0.0_2022-08-11/update-reva-beta.4.md diff --git a/changelog/2.0.0_2022-07-19/update-reva-beta.5.md b/changelog/2.0.0_2022-08-11/update-reva-beta.5.md similarity index 100% rename from changelog/2.0.0_2022-07-19/update-reva-beta.5.md rename to changelog/2.0.0_2022-08-11/update-reva-beta.5.md diff --git a/changelog/unreleased/update-reva-beta.6.md b/changelog/2.0.0_2022-08-11/update-reva-beta.6.md similarity index 100% rename from changelog/unreleased/update-reva-beta.6.md rename to changelog/2.0.0_2022-08-11/update-reva-beta.6.md diff --git a/changelog/2.0.0_2022-07-19/update-reva-beta2.md b/changelog/2.0.0_2022-08-11/update-reva-beta2.md similarity index 100% rename from changelog/2.0.0_2022-07-19/update-reva-beta2.md rename to changelog/2.0.0_2022-08-11/update-reva-beta2.md diff --git a/changelog/2.0.0_2022-07-19/update-reva-beta3.md b/changelog/2.0.0_2022-08-11/update-reva-beta3.md similarity index 100% rename from changelog/2.0.0_2022-07-19/update-reva-beta3.md rename to changelog/2.0.0_2022-08-11/update-reva-beta3.md diff --git a/changelog/2.0.0_2022-07-19/update-reva.md b/changelog/2.0.0_2022-08-11/update-reva.md similarity index 100% rename from changelog/2.0.0_2022-07-19/update-reva.md rename to changelog/2.0.0_2022-08-11/update-reva.md diff --git a/changelog/2.0.0_2022-07-19/update-web-5.5.0-beta2.md b/changelog/2.0.0_2022-08-11/update-web-5.5.0-beta2.md similarity index 100% rename from changelog/2.0.0_2022-07-19/update-web-5.5.0-beta2.md rename to changelog/2.0.0_2022-08-11/update-web-5.5.0-beta2.md diff --git a/changelog/2.0.0_2022-07-19/update-web-5.5.0-beta3.md b/changelog/2.0.0_2022-08-11/update-web-5.5.0-beta3.md similarity index 100% rename from changelog/2.0.0_2022-07-19/update-web-5.5.0-beta3.md rename to changelog/2.0.0_2022-08-11/update-web-5.5.0-beta3.md diff --git a/changelog/2.0.0_2022-07-19/update-web-5.5.0.md b/changelog/2.0.0_2022-08-11/update-web-5.5.0.md similarity index 100% rename from changelog/2.0.0_2022-07-19/update-web-5.5.0.md rename to changelog/2.0.0_2022-08-11/update-web-5.5.0.md diff --git a/changelog/2.0.0_2022-07-19/update-web-5.7.0-rc.1-beta.4.md b/changelog/2.0.0_2022-08-11/update-web-5.7.0-rc.1-beta.4.md similarity index 100% rename from changelog/2.0.0_2022-07-19/update-web-5.7.0-rc.1-beta.4.md rename to changelog/2.0.0_2022-08-11/update-web-5.7.0-rc.1-beta.4.md diff --git a/changelog/2.0.0_2022-07-19/update-web-beta.5.md b/changelog/2.0.0_2022-08-11/update-web-beta.5.md similarity index 100% rename from changelog/2.0.0_2022-07-19/update-web-beta.5.md rename to changelog/2.0.0_2022-08-11/update-web-beta.5.md diff --git a/changelog/unreleased/update-web-beta.6.md b/changelog/2.0.0_2022-08-11/update-web-beta.6.md similarity index 100% rename from changelog/unreleased/update-web-beta.6.md rename to changelog/2.0.0_2022-08-11/update-web-beta.6.md diff --git a/changelog/2.0.0_2022-07-19/urlencoding-graph-api.md b/changelog/2.0.0_2022-08-11/urlencoding-graph-api.md similarity index 100% rename from changelog/2.0.0_2022-07-19/urlencoding-graph-api.md rename to changelog/2.0.0_2022-08-11/urlencoding-graph-api.md diff --git a/changelog/2.0.0_2022-07-19/use-ldappassword-exop.md b/changelog/2.0.0_2022-08-11/use-ldappassword-exop.md similarity index 100% rename from changelog/2.0.0_2022-07-19/use-ldappassword-exop.md rename to changelog/2.0.0_2022-08-11/use-ldappassword-exop.md diff --git a/changelog/unreleased/user-expand-drive.md b/changelog/2.0.0_2022-08-11/user-expand-drive.md similarity index 100% rename from changelog/unreleased/user-expand-drive.md rename to changelog/2.0.0_2022-08-11/user-expand-drive.md diff --git a/changelog/2.0.0_2022-07-19/webdav-env-doc.md b/changelog/2.0.0_2022-08-11/webdav-env-doc.md similarity index 100% rename from changelog/2.0.0_2022-07-19/webdav-env-doc.md rename to changelog/2.0.0_2022-08-11/webdav-env-doc.md diff --git a/changelog/2.0.0_2022-07-19/webdav-search.md b/changelog/2.0.0_2022-08-11/webdav-search.md similarity index 100% rename from changelog/2.0.0_2022-07-19/webdav-search.md rename to changelog/2.0.0_2022-08-11/webdav-search.md diff --git a/changelog/CHANGELOG.tmpl b/changelog/CHANGELOG.tmpl index 1452f7f4806..dd0a2dd5734 100644 --- a/changelog/CHANGELOG.tmpl +++ b/changelog/CHANGELOG.tmpl @@ -3,7 +3,7 @@ {{ $version := .Version -}} {{/* ocis beta program */ -}} {{ if eq .Version "2.0.0" -}} -{{ $version = (printf "%v-%v" $version "beta.5") -}} +{{ $version = (printf "%v-%v" $version "beta.6") -}} {{ end -}} {{ if gt (len $allVersions) 1 -}} # Changelog for [{{ $version }}] ({{ .Date }}) diff --git a/changelog/unreleased/bugfix-idp-init-certificate-empty-file b/changelog/unreleased/bugfix-idp-init-certificate-empty-file new file mode 100644 index 00000000000..0b0967669ec --- /dev/null +++ b/changelog/unreleased/bugfix-idp-init-certificate-empty-file @@ -0,0 +1,6 @@ +Bugfix: Autocreate IDP private key also if file exists but is empty + +We've fixed the behavior for the IDP private key generation so that +a private key is also generated when the file already exists but is empty. + +https://github.com/owncloud/ocis/pull/4394 diff --git a/changelog/unreleased/change-rename-uploads-purge-clean.md b/changelog/unreleased/change-rename-uploads-purge-clean.md new file mode 100644 index 00000000000..7b131b65d37 --- /dev/null +++ b/changelog/unreleased/change-rename-uploads-purge-clean.md @@ -0,0 +1,6 @@ +Change: rename "uploads purge" command to "uploads clean" + +We've renamed the storage-users service's "uploads purge" command +to "upload clean". + +https://github.com/owncloud/ocis/pull/4403 diff --git a/changelog/unreleased/enhancement-add-open-with-web-endpoint.md b/changelog/unreleased/enhancement-add-open-with-web-endpoint.md new file mode 100644 index 00000000000..5510410574a --- /dev/null +++ b/changelog/unreleased/enhancement-add-open-with-web-endpoint.md @@ -0,0 +1,7 @@ +Enhancement: Add /app/open-with-web endpoint + +We've added an /app/open-with-web endpoint to the app provider, so that +clients that are no browser or have only limited browser access can also open apps with the help of a Web URL. + +https://github.com/owncloud/ocis/pull/4376 +https://github.com/cs3org/reva/pull/3143 diff --git a/changelog/unreleased/enhancement-app-provider-language-selection.md b/changelog/unreleased/enhancement-app-provider-language-selection.md new file mode 100644 index 00000000000..35fb7b8bef1 --- /dev/null +++ b/changelog/unreleased/enhancement-app-provider-language-selection.md @@ -0,0 +1,8 @@ +Enhancement: Added language option to the app provider + +We've added a language option to the app provider which will in the +end be passed to the app a user opens so that the web ui is displayed in the users language. + +https://github.com/owncloud/ocis/pull/4399 +https://github.com/cs3org/reva/pull/3156 +https://github.com/owncloud/ocis/issues/4367 diff --git a/changelog/unreleased/enhancment-admin-pwreset.md b/changelog/unreleased/enhancment-admin-pwreset.md new file mode 100644 index 00000000000..87931228b4c --- /dev/null +++ b/changelog/unreleased/enhancment-admin-pwreset.md @@ -0,0 +1,8 @@ +Enhancement: added command to reset administrator password + +The new command `ocis idm resetpassword` allows to reset the administrator +password when ocis is not running. So it is possible to recover setups +where the admin password was lost. + +https://github.com/owncloud/ocis/issues/4084 +https://github.com/owncloud/ocis/pull/4365 diff --git a/changelog/unreleased/update-reva-beta.7.md b/changelog/unreleased/update-reva-beta.7.md new file mode 100644 index 00000000000..b81c362c0e4 --- /dev/null +++ b/changelog/unreleased/update-reva-beta.7.md @@ -0,0 +1,7 @@ +Enhancement: update reva to vx.x.x + +Updated reva to version x.x.x. This update includes: + +* TODO: + +https://github.com/owncloud/ocis/pull/4376 diff --git a/deployments/continuous-deployment-config/ocis_keycloak/released.yml b/deployments/continuous-deployment-config/ocis_keycloak/released.yml index d5d69cb820c..06882388cda 100644 --- a/deployments/continuous-deployment-config/ocis_keycloak/released.yml +++ b/deployments/continuous-deployment-config/ocis_keycloak/released.yml @@ -32,7 +32,7 @@ env: INSECURE: "false" TRAEFIK_ACME_MAIL: wkloucek@owncloud.com - OCIS_DOCKER_TAG: 2.0.0-beta.5 + OCIS_DOCKER_TAG: 2.0.0-beta.6 OCIS_DOMAIN: ocis.ocis-keycloak.released.owncloud.works KEYCLOAK_DOMAIN: keycloak.ocis-keycloak.released.owncloud.works COMPOSE_FILE: docker-compose.yml:monitoring_tracing/docker-compose-additions.yml diff --git a/deployments/continuous-deployment-config/ocis_ldap/released.yml b/deployments/continuous-deployment-config/ocis_ldap/released.yml index 6f4f5c27860..d805c280dc3 100644 --- a/deployments/continuous-deployment-config/ocis_ldap/released.yml +++ b/deployments/continuous-deployment-config/ocis_ldap/released.yml @@ -32,7 +32,7 @@ env: INSECURE: "false" TRAEFIK_ACME_MAIL: wkloucek@owncloud.com - OCIS_DOCKER_TAG: 2.0.0-beta.5 + OCIS_DOCKER_TAG: 2.0.0-beta.6 OCIS_DOMAIN: ocis.ocis-ldap.released.owncloud.works LDAP_MANAGER_DOMAIN: ldap.ocis-ldap.released.owncloud.works COMPOSE_FILE: docker-compose.yml:monitoring_tracing/docker-compose-additions.yml diff --git a/deployments/continuous-deployment-config/ocis_traefik/released.yml b/deployments/continuous-deployment-config/ocis_traefik/released.yml index 3aad41f5064..2d111a35276 100644 --- a/deployments/continuous-deployment-config/ocis_traefik/released.yml +++ b/deployments/continuous-deployment-config/ocis_traefik/released.yml @@ -32,7 +32,7 @@ env: INSECURE: "false" TRAEFIK_ACME_MAIL: wkloucek@owncloud.com - OCIS_DOCKER_TAG: 2.0.0-beta.5 + OCIS_DOCKER_TAG: 2.0.0-beta.6 OCIS_DOMAIN: ocis.ocis-traefik.released.owncloud.works DEMO_USERS: "true" INBUCKET_DOMAIN: mail.ocis-traefik.released.owncloud.works diff --git a/deployments/continuous-deployment-config/ocis_wopi/released.yml b/deployments/continuous-deployment-config/ocis_wopi/released.yml index dda29e4ef90..b2fd4ad4d6d 100644 --- a/deployments/continuous-deployment-config/ocis_wopi/released.yml +++ b/deployments/continuous-deployment-config/ocis_wopi/released.yml @@ -32,7 +32,7 @@ env: INSECURE: "false" TRAEFIK_ACME_MAIL: wkloucek@owncloud.com - OCIS_DOCKER_TAG: 2.0.0-beta.5 + OCIS_DOCKER_TAG: 2.0.0-beta.6 OCIS_DOMAIN: ocis.ocis-wopi.released.owncloud.works WOPISERVER_DOMAIN: wopiserver.ocis-wopi.released.owncloud.works COLLABORA_DOMAIN: collabora.ocis-wopi.released.owncloud.works diff --git a/docs/services/app-registry/apps.md b/docs/services/app-registry/apps.md index 39f01d65ccb..457e2294fb1 100644 --- a/docs/services/app-registry/apps.md +++ b/docs/services/app-registry/apps.md @@ -22,9 +22,10 @@ The capabilities endpoint (e.g. `https://localhost:9200/ocs/v1.php/cloud/capabil "app_providers": [ { "enabled": true, - "version": "1.0.0", + "version": "1.1.0", "apps_url": "/app/list", "open_url": "/app/open", + "open_web_url": "/app/open-with-web", "new_url": "/app/new" } ] @@ -178,6 +179,48 @@ HTTP status code: 200 } ``` +### Open a file with the ownCloud Web + +**Endpoint**: specified in the capabilities in `open_web_url`, currently `/app/open-with-web` + +**Method**: HTTP POST + +**Authentication** (one of them): + +- `Authorization` header with OIDC Bearer token for authenticated users or basic auth credentials (if enabled in oCIS) +- `X-Access-Token` header with a REVA token for authenticated users + +**Query parameters**: + +- `file_id` (mandatory): id of the file to be opened +- `app_name` (optional) + - default (not given): default app for mime type + - possible values depend on the app providers for a mimetype from the `/app/open` endpoint + +**Request examples**: + +```bash +curl -X POST 'https://ocis.test/app/open?file_id=ZmlsZTppZAo=' + +curl -X POST 'https://ocis.test/app/open?file_id=ZmlsZTppZAo=&app_name=Collabora' +``` + +**Response examples**: + +The URI from the response JSON is intended to be opened with a GET request in a browser. If the user has not yet a session in the browser, a login flow is handled by ownCloud Web. + +HTTP status code: 200 + +```json +{ + "uri": "https://....." +} +``` + +**Example responses (error case)**: + +See error cases for [Open a file with the app provider](#open-a-file-with-the-app-provider) + ### Open a file with the app provider **Endpoint**: specified in the capabilities in `open_url`, currently `/app/open` @@ -202,12 +245,21 @@ HTTP status code: 200 - `write`: user can edit and download in the opening app - `read`: user can view and download from the opening app - `view`: user can view in the opening app (download is not possible) +- `lang` (optional) + - default (not given): default language of the application (which might maybe use the browser language) + - possible value is any ISO 639-1 language code. Examples: + - de + - en + - es + - ... **Request examples**: ```bash curl -X POST 'https://ocis.test/app/open?file_id=ZmlsZTppZAo=' +curl -X POST 'https://ocis.test/app/open?file_id=ZmlsZTppZAo=&lang=de' + curl -X POST 'https://ocis.test/app/open?file_id=ZmlsZTppZAo=&app_name=Collabora' curl -X POST 'https://ocis.test/app/open?file_id=ZmlsZTppZAo=&view_mode=read' @@ -319,6 +371,17 @@ HTTP status code: 200 } ``` +- invalid language code + + HTTP status code: 400 + + ```json + { + "code": "INVALID_PARAMETER", + "message": "lang parameter does not contain a valid ISO 639-1 language code" + } + ``` + ### Creating a file with the app provider **Endpoint**: specified in the capabilities in `new_file_url`, currently `/app/new` diff --git a/docs/services/idm/admin_password_reset.md b/docs/services/idm/admin_password_reset.md new file mode 100644 index 00000000000..1e3065c37c5 --- /dev/null +++ b/docs/services/idm/admin_password_reset.md @@ -0,0 +1,24 @@ +--- +title: Resetting a lost administrator password +date: 2022-08-29:00:00+00:00 +weight: 10 +geekdocRepo: https://github.com/owncloud/ocis +geekdocEditPath: edit/master/docs/services/idm +geekdocFilePath: admin_password_reset.md +geekdocCollapseSection: true +--- + +## Resetting a lost administrator password +By default, when using oCIS with the builtin IDM an ad generates the +user `admin` (DN `uid=admin,ou=users,o=libregraph-idm`) if, for any +reason, the password of that user is lost, it can be reset using +the `resetpassword` sub-command: + +``` +ocis idm resetpassword +``` + +It will prompt for a new password and set the password of that user +accordingly. Note: As this command is accessing the idm database directly +will only work while ocis is not running and nothing else is accessing +database. diff --git a/go.mod b/go.mod index 95487460950..fabc1ea8258 100644 --- a/go.mod +++ b/go.mod @@ -11,12 +11,12 @@ require ( github.com/blevesearch/bleve/v2 v2.3.3 github.com/coreos/go-oidc/v3 v3.2.0 github.com/cs3org/go-cs3apis v0.0.0-20220719130120-361e9f987d64 - github.com/cs3org/reva/v2 v2.7.5-0.20220815083220-15056d90bdd5 + github.com/cs3org/reva/v2 v2.7.5-0.20220818115656-164699f71ceb github.com/disintegration/imaging v1.6.2 github.com/ggwhite/go-masker v1.0.9 github.com/go-chi/chi/v5 v5.0.7 github.com/go-chi/cors v1.2.1 - github.com/go-chi/render v1.0.1 + github.com/go-chi/render v1.0.2 github.com/go-ldap/ldap/v3 v3.4.4 github.com/go-ldap/ldif v0.0.0-20200320164324-fd88d9b715b3 github.com/go-micro/plugins/v4/client/grpc v1.1.0 @@ -41,7 +41,7 @@ require ( github.com/gorilla/mux v1.8.0 github.com/grpc-ecosystem/grpc-gateway/v2 v2.11.2 github.com/justinas/alice v1.2.0 - github.com/libregraph/idm v0.3.1-0.20220718103124-c4f6613dce2b + github.com/libregraph/idm v0.3.1-0.20220808071235-17bb032176de github.com/libregraph/lico v0.54.1-0.20220325072321-31efc3995d63 github.com/mitchellh/mapstructure v1.5.0 github.com/mohae/deepcopy v0.0.0-20170929034955-c48cc78d4826 @@ -65,6 +65,7 @@ require ( github.com/urfave/cli/v2 v2.11.1 github.com/xhit/go-simple-mail/v2 v2.11.0 go-micro.dev/v4 v4.8.0 + go.etcd.io/bbolt v1.3.6 go.opencensus.io v0.23.0 go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.34.0 go.opentelemetry.io/otel v1.9.0 @@ -76,6 +77,7 @@ require ( golang.org/x/image v0.0.0-20220321031419-a8550c1d254a golang.org/x/net v0.0.0-20220624214902-1bab6f366d9e golang.org/x/oauth2 v0.0.0-20220722155238-128564f6959c + golang.org/x/term v0.0.0-20220722155259-a9ba230a4035 google.golang.org/genproto v0.0.0-20220805133916-01dd62135a58 google.golang.org/grpc v1.48.0 google.golang.org/protobuf v1.28.1 @@ -95,6 +97,7 @@ require ( github.com/ProtonMail/go-crypto v0.0.0-20211112122917-428f8eabeeb3 // indirect github.com/RoaringBitmap/roaring v0.9.4 // indirect github.com/acomagu/bufpipe v1.0.3 // indirect + github.com/ajg/form v1.5.1 // indirect github.com/alexedwards/argon2id v0.0.0-20211130144151-3585854a6387 // indirect github.com/amoghe/go-crypt v0.0.0-20220222110647-20eada5f5964 // indirect github.com/armon/go-metrics v0.3.10 // indirect @@ -122,6 +125,7 @@ require ( github.com/blevesearch/zapx/v15 v15.3.4 // indirect github.com/bluele/gcache v0.0.2 // indirect github.com/bmizerany/pat v0.0.0-20210406213842-e4b6760bdd6f // indirect + github.com/bombsimon/logrusr/v3 v3.0.0 // indirect github.com/cenkalti/backoff v2.2.1+incompatible // indirect github.com/ceph/go-ceph v0.15.0 // indirect github.com/cespare/xxhash/v2 v2.1.2 // indirect @@ -140,6 +144,7 @@ require ( github.com/dlclark/regexp2 v1.4.0 // indirect github.com/dustin/go-humanize v1.0.0 // indirect github.com/emirpasic/gods v1.12.0 // indirect + github.com/emvi/iso-639-1 v1.0.1 // indirect github.com/eternnoir/gncp v0.0.0-20170707042257-c70df2d0cd68 // indirect github.com/evanphx/json-patch/v5 v5.5.0 // indirect github.com/fatih/color v1.13.0 // indirect @@ -256,7 +261,6 @@ require ( github.com/wk8/go-ordered-map v1.0.0 // indirect github.com/xanzy/ssh-agent v0.3.1 // indirect github.com/xrash/smetrics v0.0.0-20201216005158-039620a65673 // indirect - go.etcd.io/bbolt v1.3.6 // indirect go.etcd.io/etcd/api/v3 v3.5.2 // indirect go.etcd.io/etcd/client/pkg/v3 v3.5.2 // indirect go.etcd.io/etcd/client/v3 v3.5.2 // indirect diff --git a/go.sum b/go.sum index 75d9df1c11f..8524411e532 100644 --- a/go.sum +++ b/go.sum @@ -83,7 +83,6 @@ github.com/Azure/go-autorest/tracing v0.1.0/go.mod h1:ROEEAFwXycQw7Sn3DXNtEedEvd github.com/Azure/go-autorest/tracing v0.5.0/go.mod h1:r/s2XiOKccPW3HrqB+W0TQzfbtp2fGCgRFtBroKn4Dk= github.com/Azure/go-autorest/tracing v0.6.0/go.mod h1:+vhtPC754Xsa23ID7GlGsrdKBpUA79WCAKPPZVC2DeU= github.com/Azure/go-ntlmssp v0.0.0-20200615164410-66371956d46c/go.mod h1:chxPXzSsl7ZWRAuOIE23GDNzjWuZquvFlgA8xmpunjU= -github.com/Azure/go-ntlmssp v0.0.0-20211209120228-48547f28849e/go.mod h1:chxPXzSsl7ZWRAuOIE23GDNzjWuZquvFlgA8xmpunjU= github.com/Azure/go-ntlmssp v0.0.0-20220621081337-cb9428e4ac1e h1:NeAW1fUYUEWhft7pkxDf6WoUvEZJ/uOKsvtpjLnn8MU= github.com/Azure/go-ntlmssp v0.0.0-20220621081337-cb9428e4ac1e/go.mod h1:chxPXzSsl7ZWRAuOIE23GDNzjWuZquvFlgA8xmpunjU= github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= @@ -124,6 +123,8 @@ github.com/Songmu/prompter v0.5.1/go.mod h1:CS3jEPD6h9IaLaG6afrl1orTgII9+uDWuw95 github.com/acomagu/bufpipe v1.0.3 h1:fxAGrHZTgQ9w5QqVItgzwj235/uYZYgbXitB+dLupOk= github.com/acomagu/bufpipe v1.0.3/go.mod h1:mxdxdup/WdsKVreO5GpW4+M/1CE2sMG4jeGJ2sYmHc4= github.com/agext/levenshtein v1.2.1/go.mod h1:JEDfjyjHDjOF/1e4FlBE/PkbqA9OfWu2ki2W0IB5558= +github.com/ajg/form v1.5.1 h1:t9c7v8JUKu/XxOGBU0yjNpaMloxGEJhUkqFRq0ibGeU= +github.com/ajg/form v1.5.1/go.mod h1:uL1WgH+h2mgNtvBq0339dVnzXdBETtL2LeUXaIv25UY= github.com/akamai/AkamaiOPEN-edgegrid-golang v1.1.0/go.mod h1:kX6YddBkXqqywAe8c9LyvgTCyFuZCTMF4cRPQhc3Fy8= github.com/alecthomas/template v0.0.0-20160405071501-a0175ee3bccc/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc= github.com/alecthomas/template v0.0.0-20190718012654-fb15b899a751/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc= @@ -226,6 +227,8 @@ github.com/bmizerany/assert v0.0.0-20160611221934-b7ed37b82869/go.mod h1:Ekp36dR github.com/bmizerany/pat v0.0.0-20170815010413-6226ea591a40/go.mod h1:8rLXio+WjiTceGBHIoTvn60HIbs7Hm7bcHjyrSqYB9c= github.com/bmizerany/pat v0.0.0-20210406213842-e4b6760bdd6f h1:gOO/tNZMjjvTKZWpY7YnXC72ULNLErRtp94LountVE8= github.com/bmizerany/pat v0.0.0-20210406213842-e4b6760bdd6f/go.mod h1:8rLXio+WjiTceGBHIoTvn60HIbs7Hm7bcHjyrSqYB9c= +github.com/bombsimon/logrusr/v3 v3.0.0 h1:tcAoLfuAhKP9npBxWzSdpsvKPQt1XV02nSf2lZA82TQ= +github.com/bombsimon/logrusr/v3 v3.0.0/go.mod h1:PksPPgSFEL2I52pla2glgCyyd2OqOHAnFF5E+g8Ixco= github.com/boombuler/barcode v1.0.1-0.20190219062509-6c824513bacc/go.mod h1:paBWMcWSl3LHKBqUq+rly7CNSldXjb2rDl3JlRe0mD8= github.com/c-bata/go-prompt v0.2.5/go.mod h1:vFnjEGDIIA/Lib7giyE4E9c50Lvl8j0S+7FVlAwDAVw= github.com/cenkalti/backoff v2.2.1+incompatible h1:tNowT99t7UNflLxfYYSlKYsBpXdEet03Pg2g16Swow4= @@ -290,8 +293,8 @@ github.com/crewjam/saml v0.4.6 h1:XCUFPkQSJLvzyl4cW9OvpWUbRf0gE7VUpU8ZnilbeM4= github.com/crewjam/saml v0.4.6/go.mod h1:ZBOXnNPFzB3CgOkRm7Nd6IVdkG+l/wF+0ZXLqD96t1A= github.com/cs3org/go-cs3apis v0.0.0-20220719130120-361e9f987d64 h1:cFnankJOCWndnOns4sKRG7yzH61ammK2Am6rEGWCK40= github.com/cs3org/go-cs3apis v0.0.0-20220719130120-361e9f987d64/go.mod h1:UXha4TguuB52H14EMoSsCqDj7k8a/t7g4gVP+bgY5LY= -github.com/cs3org/reva/v2 v2.7.5-0.20220815083220-15056d90bdd5 h1:q6UTyb+K3yGygbvjmFXypZqrWZUWobm7ospe3gSwJN4= -github.com/cs3org/reva/v2 v2.7.5-0.20220815083220-15056d90bdd5/go.mod h1:2TY/LuIbnzpIqbL0J7AtVAaVOGw30zuZkWsPIPbW1pU= +github.com/cs3org/reva/v2 v2.7.5-0.20220818115656-164699f71ceb h1:yRbu+LAJbxHnzhzH13Sv5oMlsGixMGLxnXr3LjXd9uU= +github.com/cs3org/reva/v2 v2.7.5-0.20220818115656-164699f71ceb/go.mod h1:79CY/x0samKw7azYn2gzTFv0jvr2WO4JTKZwCb/+SEU= github.com/cubewise-code/go-mime v0.0.0-20200519001935-8c5762b177d8 h1:Z9lwXumT5ACSmJ7WGnFl+OMLLjpz5uR2fyz7dC255FI= github.com/cubewise-code/go-mime v0.0.0-20200519001935-8c5762b177d8/go.mod h1:4abs/jPXcmJzYoYGF91JF9Uq9s/KL5n1jvFDix8KcqY= github.com/cyberdelia/templates v0.0.0-20141128023046-ca7fffd4298c/go.mod h1:GyV+0YP4qX0UQ7r2MoYZ+AvYDp12OF5yg4q8rGnyNh4= @@ -325,6 +328,8 @@ github.com/eapache/go-xerial-snappy v0.0.0-20180814174437-776d5712da21/go.mod h1 github.com/eapache/queue v1.1.0/go.mod h1:6eCeP0CKFpHLu8blIFXhExK/dRa7WDZfr6jVFPTqq+I= github.com/emirpasic/gods v1.12.0 h1:QAUIPSaCu4G+POclxeqb3F+WPpdKqFGlw36+yOzGlrg= github.com/emirpasic/gods v1.12.0/go.mod h1:YfzfFFoVP/catgzJb4IKIqXjX78Ha8FMSDh3ymbK86o= +github.com/emvi/iso-639-1 v1.0.1 h1:4s6P8Uxc/RDkwCpxAr4NHOT/15a1swy9IQkB8PJCWVI= +github.com/emvi/iso-639-1 v1.0.1/go.mod h1:mghC4MDFyszxzH98ujf/K5whvB6B0nV4qCa5u94dP84= github.com/envoyproxy/go-control-plane v0.9.0/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= github.com/envoyproxy/go-control-plane v0.9.1-0.20191026205805-5f8ba28d4473/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= github.com/envoyproxy/go-control-plane v0.9.4/go.mod h1:6rpuAdCZL397s3pYoYcLgu1mIlRU8Am5FuJP05cCM98= @@ -379,8 +384,8 @@ github.com/go-chi/chi/v5 v5.0.7 h1:rDTPXLDHGATaeHvVlLcR4Qe0zftYethFucbjVQ1PxU8= github.com/go-chi/chi/v5 v5.0.7/go.mod h1:DslCQbL2OYiznFReuXYUmQ2hGd1aDpCnlMNITLSKoi8= github.com/go-chi/cors v1.2.1 h1:xEC8UT3Rlp2QuWNEr4Fs/c2EAGVKBwy/1vHx3bppil4= github.com/go-chi/cors v1.2.1/go.mod h1:sSbTewc+6wYHBBCW7ytsFSn836hqM7JxpglAy2Vzc58= -github.com/go-chi/render v1.0.1 h1:4/5tis2cKaNdnv9zFLfXzcquC9HbeZgCnxGnKrltBS8= -github.com/go-chi/render v1.0.1/go.mod h1:pq4Rr7HbnsdaeHagklXub+p6Wd16Af5l9koip1OvJns= +github.com/go-chi/render v1.0.2 h1:4ER/udB0+fMWB2Jlf15RV3F4A2FDuYi/9f+lFttR/Lg= +github.com/go-chi/render v1.0.2/go.mod h1:/gr3hVkmYR0YlEy3LxCuVRFzEu9Ruok+gFqbIofjao0= github.com/go-cmd/cmd v1.0.5/go.mod h1:y8q8qlK5wQibcw63djSl/ntiHUHXHGdCkPk0j4QeW4s= github.com/go-errors/errors v1.0.1/go.mod h1:f4zRHt4oKfwPJE5k8C9vpYG+aDHdBFUsgrm6/TyX73Q= github.com/go-git/gcfg v1.5.0 h1:Q5ViNfGF8zFgyJWPqYwA7qGFoMTEiBmdlkcfRmpIMa4= @@ -402,7 +407,6 @@ github.com/go-kit/log v0.2.0 h1:7i2K3eKTos3Vc0enKCfnVcgHh2olr/MyfboYq7cAcFw= github.com/go-kit/log v0.2.0/go.mod h1:NwTd00d/i8cPZ3xOwwiv2PO5MOcx78fFErGNcVmBjv0= github.com/go-ldap/ldap/v3 v3.1.7/go.mod h1:5Zun81jBTabRaI8lzN7E1JjyEl1g6zI6u9pd8luAK4Q= github.com/go-ldap/ldap/v3 v3.4.2/go.mod h1:iYS1MdmrmceOJ1QOTnRXrIs7i3kloqtmGQjRvjKpyMg= -github.com/go-ldap/ldap/v3 v3.4.3/go.mod h1:7LdHfVt6iIOESVEe3Bs4Jp2sHEKgDeduAhgM1/f9qmo= github.com/go-ldap/ldap/v3 v3.4.4 h1:qPjipEpt+qDa6SI/h1fzuGWoRUY+qqQ9sOZq67/PYUs= github.com/go-ldap/ldap/v3 v3.4.4/go.mod h1:fe1MsuN5eJJ1FeLT/LEBVdWfNWKh459R7aXgXtJC+aI= github.com/go-ldap/ldif v0.0.0-20200320164324-fd88d9b715b3 h1:sfz1YppV05y4sYaW7kXZtrocU/+vimnIWt4cxAYh7+o= @@ -813,8 +817,8 @@ github.com/labbsr0x/goh v1.0.1/go.mod h1:8K2UhVoaWXcCU7Lxoa2omWnC8gyW8px7/lmO61c github.com/labstack/echo/v4 v4.1.11/go.mod h1:i541M3Fj6f76NZtHSj7TXnyM8n2gaodfvfxNnFqi74g= github.com/labstack/gommon v0.3.0/go.mod h1:MULnywXg0yavhxWKc+lOruYdAhDwPK9wf0OL7NoOu+k= github.com/leodido/go-urn v1.2.0/go.mod h1:+8+nEpDfqqsY+g338gtMEUOtuK+4dEMhiQEgxpxOKII= -github.com/libregraph/idm v0.3.1-0.20220718103124-c4f6613dce2b h1:/BNTnfP6lqixKUP2kP9gKWiPRaBWvE5BJcFcIVd2Ekg= -github.com/libregraph/idm v0.3.1-0.20220718103124-c4f6613dce2b/go.mod h1:ggVmYkaK5fu680QOnxkuyCRW5Wl5qzaYXgIiieNBOJE= +github.com/libregraph/idm v0.3.1-0.20220808071235-17bb032176de h1:iDKkd+RQt/sddvPNQrfFQkExbyt4gxDyTQyi9DkP/c0= +github.com/libregraph/idm v0.3.1-0.20220808071235-17bb032176de/go.mod h1:syzZjsjzpnjGibVayqnIywXSvvGanU8cDd9uotqoPcw= github.com/libregraph/lico v0.54.1-0.20220325072321-31efc3995d63 h1:oPqyRePmq+59YF1tAur7WXuM/z/epRd+HGGyPPx2Vv8= github.com/libregraph/lico v0.54.1-0.20220325072321-31efc3995d63/go.mod h1:KZ4X+bEbOQMSV6iPysZEqVO/Pa5Mvo7xhhcLwUNPjmw= github.com/linode/linodego v0.25.3/go.mod h1:GSBKPpjoQfxEfryoCRcgkuUOCuVtGHWhzI8OMdycNTE= @@ -1018,7 +1022,6 @@ github.com/prometheus/client_golang v1.7.1/go.mod h1:PY5Wy2awLA44sXw4AOSfFBetzPP github.com/prometheus/client_golang v1.11.0/go.mod h1:Z6t4BnS23TR94PD6BsDNk8yVqroYurpAkEiz0P2BEV0= github.com/prometheus/client_golang v1.11.1/go.mod h1:Z6t4BnS23TR94PD6BsDNk8yVqroYurpAkEiz0P2BEV0= github.com/prometheus/client_golang v1.12.1/go.mod h1:3Z9XVyYiZYEO+YQWt3RD2R3jrbd179Rt297l4aS6nDY= -github.com/prometheus/client_golang v1.12.2/go.mod h1:3Z9XVyYiZYEO+YQWt3RD2R3jrbd179Rt297l4aS6nDY= github.com/prometheus/client_golang v1.13.0 h1:b71QUfeo5M8gq2+evJdTPfZhYMAU0uKPkyPJ7TPsloU= github.com/prometheus/client_golang v1.13.0/go.mod h1:vTeo+zgvILHsnnj/39Ou/1fPN5nJFOEMgftOUOmlvYQ= github.com/prometheus/client_model v0.0.0-20170216185247-6f3806018612/go.mod h1:MbSGuTsp3dbXC40dX6PRTWyKYBIrTGTE9sqQNg2J8bo= @@ -1312,7 +1315,6 @@ golang.org/x/crypto v0.0.0-20210616213533-5ff15b29337e/go.mod h1:GvvjBRRGRdwPK5y golang.org/x/crypto v0.0.0-20210711020723-a769d52b0f97/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= golang.org/x/crypto v0.0.0-20211117183948-ae814b36b871/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= golang.org/x/crypto v0.0.0-20220321153916-2c7772ba3064/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= -golang.org/x/crypto v0.0.0-20220331220935-ae2d96664a29/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= golang.org/x/crypto v0.0.0-20220622213112-05595931fe9d/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= golang.org/x/crypto v0.0.0-20220722155217-630584e8d5aa h1:zuSxTR4o9y82ebqCUJYNGJbGPo6sKVl54f/TVDObg1c= golang.org/x/crypto v0.0.0-20220722155217-630584e8d5aa/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= @@ -1454,6 +1456,7 @@ golang.org/x/sync v0.0.0-20200625203802-6e8e738ad208/go.mod h1:RxMgew5VJxzue5/jJ golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20201207232520-09787c993a3a/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20210220032951-036812b2e83c/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sync v0.0.0-20220601150217-0de741cfad7f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4 h1:uVc8UZUe6tr40fFVnUP5Oj+veunVezqYl9z7DYw9xzw= golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sys v0.0.0-20180622082034-63fc586f45fe/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= @@ -1563,6 +1566,7 @@ golang.org/x/sys v0.0.0-20220227234510-4e6760a101f9/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20220328115105-d36c6a25d886/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220408201424-a24fb2fb8a0f/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220412211240-33da011f77ad/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220422013727-9388b58f7150/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220503163025-988cb79eb6c6/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220715151400-c0bba94af5f8/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= @@ -1573,6 +1577,7 @@ golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9sn golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= golang.org/x/term v0.0.0-20220526004731-065cf7ba2467/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= golang.org/x/term v0.0.0-20220722155259-a9ba230a4035 h1:Q5284mrmYTpACcm+eAKjKJH48BBwSyfJqmmGDTtT8Vc= +golang.org/x/term v0.0.0-20220722155259-a9ba230a4035/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= golang.org/x/text v0.0.0-20170915032832-14c0d48ead0c/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.1-0.20180807135948-17ff2d5776d2/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= diff --git a/ocis-pkg/version/version.go b/ocis-pkg/version/version.go index b506bf2778c..3bec98f9d62 100644 --- a/ocis-pkg/version/version.go +++ b/ocis-pkg/version/version.go @@ -16,7 +16,7 @@ var ( // LatestTag is the latest released version plus the dev meta version. // Will be overwritten by the release pipeline // Needs a manual change for every tagged release - LatestTag = "2.0.0-beta.5+dev" + LatestTag = "2.0.0-beta.6+dev" // Date indicates the build date. Date = time.Now().Format("20060102") diff --git a/services/audit/pkg/command/root.go b/services/audit/pkg/command/root.go index 025dc925d6e..cfe85a70901 100644 --- a/services/audit/pkg/command/root.go +++ b/services/audit/pkg/command/root.go @@ -49,6 +49,7 @@ func NewSutureService(cfg *ociscfg.Config) suture.Service { } } +// Serve implements Server interface func (s SutureService) Serve(ctx context.Context) error { s.cfg.Context = ctx if err := Execute(s.cfg); err != nil { diff --git a/services/audit/pkg/config/config.go b/services/audit/pkg/config/config.go index d0ccca9e914..48cadb0db68 100644 --- a/services/audit/pkg/config/config.go +++ b/services/audit/pkg/config/config.go @@ -23,7 +23,7 @@ type Config struct { // Events combines the configuration options for the event bus. type Events struct { - Endpoint string `yaml:"endpoint" env:"AUDIT_EVENTS_ENDPOINT" desc:"The address of the event system. The event system is the message queuing service. It is used as message broker for the microservice architecture.` + Endpoint string `yaml:"endpoint" env:"AUDIT_EVENTS_ENDPOINT" desc:"The address of the event system. The event system is the message queuing service. It is used as message broker for the microservice architecture."` Cluster string `yaml:"cluster" env:"AUDIT_EVENTS_CLUSTER" desc:"The clusterID of the event system. The event system is the message queuing service. It is used as message broker for the microservice architecture. Mandatory when using NATS as event system."` ConsumerGroup string `yaml:"group" env:"AUDIT_EVENTS_GROUP" desc:"The consumergroup of the service. One group will only get one copy of an event."` } diff --git a/services/audit/pkg/config/defaults/defaultconfig.go b/services/audit/pkg/config/defaults/defaultconfig.go index 34af1c788dc..5a4286cbc57 100644 --- a/services/audit/pkg/config/defaults/defaultconfig.go +++ b/services/audit/pkg/config/defaults/defaultconfig.go @@ -4,6 +4,7 @@ import ( "github.com/owncloud/ocis/v2/services/audit/pkg/config" ) +// FullDefaultConfig returns a fully initialized default configuration func FullDefaultConfig() *config.Config { cfg := DefaultConfig() EnsureDefaults(cfg) @@ -11,6 +12,7 @@ func FullDefaultConfig() *config.Config { return cfg } +// DefaultConfig returns a basic default configuration func DefaultConfig() *config.Config { return &config.Config{ Debug: config.Debug{ @@ -31,6 +33,7 @@ func DefaultConfig() *config.Config { } } +// EnsureDefaults adds default values to the configuration if they are not set yet func EnsureDefaults(cfg *config.Config) { // provide with defaults for shared logging, since we need a valid destination address for "envdecode". if cfg.Log == nil && cfg.Commons != nil && cfg.Commons.Log != nil { @@ -45,6 +48,7 @@ func EnsureDefaults(cfg *config.Config) { } } +// Sanitize sanitized the configuration func Sanitize(cfg *config.Config) { // sanitize config } diff --git a/services/audit/pkg/config/parser/parse.go b/services/audit/pkg/config/parser/parse.go index 43adabd426f..f4e5f3d6835 100644 --- a/services/audit/pkg/config/parser/parse.go +++ b/services/audit/pkg/config/parser/parse.go @@ -32,6 +32,7 @@ func ParseConfig(cfg *config.Config) error { return Validate(cfg) } +// Validate validates the configuration func Validate(cfg *config.Config) error { return nil } diff --git a/services/audit/pkg/logging/logging.go b/services/audit/pkg/logging/logging.go index 4acd0282b93..01f0569fa47 100644 --- a/services/audit/pkg/logging/logging.go +++ b/services/audit/pkg/logging/logging.go @@ -5,7 +5,7 @@ import ( "github.com/owncloud/ocis/v2/services/audit/pkg/config" ) -// LoggerFromConfig initializes a service-specific logger instance. +// Configure initializes a service-specific logger instance. func Configure(name string, cfg *config.Log) log.Logger { return log.NewLogger( log.Name(name), diff --git a/services/audit/pkg/service/service.go b/services/audit/pkg/service/service.go index 961c4196348..621eaf8ec80 100644 --- a/services/audit/pkg/service/service.go +++ b/services/audit/pkg/service/service.go @@ -34,7 +34,7 @@ func AuditLoggerFromConfig(ctx context.Context, cfg config.Auditlog, ch <-chan i } -// StartAuditLogger will block. run in seperate go routine +// StartAuditLogger will block. run in separate go routine func StartAuditLogger(ctx context.Context, ch <-chan interface{}, log log.Logger, marshaller Marshaller, logto ...Log) { for { select { diff --git a/services/audit/pkg/types/conversion.go b/services/audit/pkg/types/conversion.go index 14cea5a0157..c98b2caf491 100644 --- a/services/audit/pkg/types/conversion.go +++ b/services/audit/pkg/types/conversion.go @@ -13,6 +13,8 @@ import ( types "github.com/cs3org/go-cs3apis/cs3/types/v1beta1" ) +const _linktype = "link" + // BasicAuditEvent creates an AuditEvent from given values func BasicAuditEvent(uid string, ctime string, msg string, action string) AuditEvent { return AuditEvent{ @@ -68,7 +70,7 @@ func ShareCreated(ev events.ShareCreated) AuditEventShareCreated { // LinkCreated converts a ShareCreated Event to an AuditEventShareCreated func LinkCreated(ev events.LinkCreated) AuditEventShareCreated { uid := ev.Sharer.OpaqueId - with, typ := "", "link" + with, typ := "", _linktype base := BasicAuditEvent(uid, formatTime(ev.CTime), MessageLinkCreated(uid, ev.ItemID.OpaqueId, ev.ShareID.OpaqueId), ActionShareCreated) return AuditEventShareCreated{ AuditEventSharing: SharingAuditEvent("", ev.ItemID.OpaqueId, uid, base), @@ -108,7 +110,7 @@ func ShareUpdated(ev events.ShareUpdated) AuditEventShareUpdated { // LinkUpdated converts a LinkUpdated event to an AuditEventShareUpdated func LinkUpdated(ev events.LinkUpdated) AuditEventShareUpdated { uid := ev.Sharer.OpaqueId - with, typ := "", "link" + with, typ := "", _linktype base := BasicAuditEvent(uid, formatTime(ev.CTime), MessageLinkUpdated(uid, ev.ShareID.OpaqueId, ev.FieldUpdated), updateType(ev.FieldUpdated)) return AuditEventShareUpdated{ AuditEventSharing: SharingAuditEvent(ev.ShareID.GetOpaqueId(), ev.ItemID.OpaqueId, uid, base), @@ -150,7 +152,7 @@ func ShareRemoved(ev events.ShareRemoved) AuditEventShareRemoved { // LinkRemoved converts a LinkRemoved event to an AuditEventShareRemoved func LinkRemoved(ev events.LinkRemoved) AuditEventShareRemoved { - uid, sid, typ := ev.Executant.GetOpaqueId(), "", "link" + uid, sid, typ := ev.Executant.GetOpaqueId(), "", _linktype if ev.ShareID != nil { sid = ev.ShareID.GetOpaqueId() } else { diff --git a/services/frontend/pkg/command/server.go b/services/frontend/pkg/command/server.go index 20719e36ccc..91fcdf1fc3c 100644 --- a/services/frontend/pkg/command/server.go +++ b/services/frontend/pkg/command/server.go @@ -48,7 +48,10 @@ func Server(cfg *config.Config) *cli.Command { pidFile := path.Join(os.TempDir(), "revad-"+cfg.Service.Name+"-"+uuid.Must(uuid.NewV4()).String()+".pid") - rcfg := revaconfig.FrontendConfigFromStruct(cfg) + rcfg, err := revaconfig.FrontendConfigFromStruct(cfg) + if err != nil { + return err + } gr.Add(func() error { runtime.RunWithOptions(rcfg, pidFile, runtime.WithLogger(&logger.Logger)) diff --git a/services/frontend/pkg/revaconfig/config.go b/services/frontend/pkg/revaconfig/config.go index adf00ee0922..0b386d2545c 100644 --- a/services/frontend/pkg/revaconfig/config.go +++ b/services/frontend/pkg/revaconfig/config.go @@ -1,6 +1,7 @@ package revaconfig import ( + "net/url" "path" "strconv" @@ -9,7 +10,15 @@ import ( ) // FrontendConfigFromStruct will adapt an oCIS config struct into a reva mapstructure to start a reva service. -func FrontendConfigFromStruct(cfg *config.Config) map[string]interface{} { +func FrontendConfigFromStruct(cfg *config.Config) (map[string]interface{}, error) { + + webURL, err := url.Parse(cfg.PublicURL) + if err != nil { + return nil, err + } + webURL.Path = path.Join(webURL.Path, "external") + webOpenInAppURL := webURL.String() + archivers := []map[string]interface{}{ { "enabled": true, @@ -23,11 +32,12 @@ func FrontendConfigFromStruct(cfg *config.Config) map[string]interface{} { appProviders := []map[string]interface{}{ { - "enabled": true, - "version": "1.0.0", - "apps_url": "/app/list", - "open_url": "/app/open", - "new_url": "/app/new", + "enabled": true, + "version": "1.1.0", + "apps_url": "/app/list", + "open_url": "/app/open", + "open_web_url": "/app/open-with-web", + "new_url": "/app/new", }, } @@ -89,6 +99,18 @@ func FrontendConfigFromStruct(cfg *config.Config) map[string]interface{} { "transfer_shared_secret": cfg.TransferSecret, "timeout": 86400, "insecure": cfg.AppHandler.Insecure, + "webbaseuri": webOpenInAppURL, + "web": map[string]interface{}{ + "urlparamsmapping": map[string]string{ + // param -> value mapper + // these mappers are static and are only subject to change when changed in oC Web + "fileId": "fileid", + "app": "appname", + }, + "staticurlparams": map[string]string{ + "contextRouteName": "files-spaces-personal", // TODO: remove when https://github.com/owncloud/web/pull/7437 arrived in oCIS + }, + }, }, "archiver": map[string]interface{}{ "prefix": cfg.Archiver.Prefix, @@ -228,5 +250,5 @@ func FrontendConfigFromStruct(cfg *config.Config) map[string]interface{} { }, }, }, - } + }, nil } diff --git a/services/idm/pkg/command/resetpw.go b/services/idm/pkg/command/resetpw.go new file mode 100644 index 00000000000..7fd5c52eba4 --- /dev/null +++ b/services/idm/pkg/command/resetpw.go @@ -0,0 +1,118 @@ +package command + +import ( + "context" + "errors" + "fmt" + "os" + "syscall" + "time" + + "github.com/go-ldap/ldap/v3" + "github.com/libregraph/idm/pkg/ldbbolt" + "github.com/libregraph/idm/server" + "github.com/owncloud/ocis/v2/ocis-pkg/log" + "github.com/owncloud/ocis/v2/services/idm/pkg/config" + "github.com/owncloud/ocis/v2/services/idm/pkg/config/parser" + "github.com/owncloud/ocis/v2/services/idm/pkg/logging" + "github.com/urfave/cli/v2" + bolt "go.etcd.io/bbolt" + "golang.org/x/term" +) + +// ResetPassword is the entrypoint for the resetpassword command +func ResetPassword(cfg *config.Config) *cli.Command { + return &cli.Command{ + Name: "resetpassword", + Usage: fmt.Sprintf("Reset admin password"), + Category: "password reset", + Before: func(c *cli.Context) error { + err := parser.ParseConfig(cfg) + if err != nil { + fmt.Printf("%v", err) + os.Exit(1) + } + return err + }, + Action: func(c *cli.Context) error { + logger := logging.Configure(cfg.Service.Name, cfg.Log) + ctx, cancel := func() (context.Context, context.CancelFunc) { + if cfg.Context == nil { + return context.WithCancel(context.Background()) + } + return context.WithCancel(cfg.Context) + }() + + defer cancel() + return resetPassword(ctx, logger, cfg) + }, + } +} + +func resetPassword(ctx context.Context, logger log.Logger, cfg *config.Config) error { + servercfg := server.Config{ + Logger: log.LogrusWrap(logger.Logger), + LDAPHandler: "boltdb", + LDAPBaseDN: "o=libregraph-idm", + + BoltDBFile: cfg.IDM.DatabasePath, + } + + adminUserDN := "uid=admin,ou=users," + servercfg.LDAPBaseDN + fmt.Printf("Resetting password for user '%s'.\n", adminUserDN) + if _, err := os.Stat(servercfg.BoltDBFile); errors.Is(err, os.ErrNotExist) { + fmt.Fprintf(os.Stderr, "IDM database does not exist.\n") + return err + } + + newPw, err := getPassword() + if err != nil { + fmt.Fprintf(os.Stderr, "Error reading password: %v\n", err) + return err + } + + bdb := &ldbbolt.LdbBolt{} + + opts := bolt.Options{ + Timeout: 1 * time.Millisecond, + } + if err := bdb.Configure(servercfg.Logger, servercfg.LDAPBaseDN, servercfg.BoltDBFile, &opts); err != nil { + fmt.Fprintf(os.Stderr, "Failed to open database: '%s'. Please stop any running ocis/idm instance, as this tool requires exclusive access to the database.\n", err) + return err + } + defer bdb.Close() + + if err := bdb.Initialize(); err != nil { + return err + } + + pwRequest := ldap.NewPasswordModifyRequest(adminUserDN, "", newPw) + if err := bdb.UpdatePassword(pwRequest); err != nil { + fmt.Fprintf(os.Stderr, "Failed to update admin password: %v\n", err) + } + fmt.Printf("Password for user '%s' updated.\n", adminUserDN) + return nil +} + +func getPassword() (string, error) { + fmt.Print("Enter new password: ") + bytePassword, err := term.ReadPassword(int(syscall.Stdin)) + if err != nil { + return "", err + } + fmt.Println("") + fmt.Print("Re-enter new password: ") + bytePasswordVerify, err := term.ReadPassword(int(syscall.Stdin)) + if err != nil { + return "", err + } + fmt.Println("") + + password := string(bytePassword) + passwordVerify := string(bytePasswordVerify) + + if password != passwordVerify { + return "", errors.New("Passwords do not match") + } + return password, nil +} diff --git a/services/idm/pkg/command/root.go b/services/idm/pkg/command/root.go index 84208cba848..ee1ccb95d92 100644 --- a/services/idm/pkg/command/root.go +++ b/services/idm/pkg/command/root.go @@ -18,6 +18,7 @@ func GetCommands(cfg *config.Config) cli.Commands { Server(cfg), // interaction with this service + ResetPassword(cfg), // infos about this service Health(cfg), diff --git a/services/idp/pkg/command/server.go b/services/idp/pkg/command/server.go index 6e6be436ab4..4991a385e33 100644 --- a/services/idp/pkg/command/server.go +++ b/services/idp/pkg/command/server.go @@ -161,12 +161,12 @@ func ensureEncryptionSecretExists(path string) error { func ensureSigningPrivateKeyExists(paths []string) error { for _, path := range paths { - _, err := os.Stat(path) - if err == nil { - // If the file exists we can just return + file, err := os.Stat(path) + if err == nil && file.Size() > 0 { + // If the file exists and is not empty we can just return return nil } - if !errors.Is(err, fs.ErrNotExist) { + if !errors.Is(err, fs.ErrNotExist) && file.Size() > 0 { return err } diff --git a/services/settings/.golangci.yml b/services/settings/.golangci.yml deleted file mode 100644 index 4bb1586f744..00000000000 --- a/services/settings/.golangci.yml +++ /dev/null @@ -1,38 +0,0 @@ -issues: - exclude-rules: - - path: pkg/proto/v0/settings.pb.go - text: "SA1019:" - linters: - - staticcheck - - path: pkg/store/filesystem/io.go - text: "SA1019:" - linters: - - staticcheck - # Exclude scopelint for tests files because of https://github.com/kyoh86/scopelint/issues/4 - - path: _test\.go - linters: - - scopelint -linters: - enable: - - bodyclose - - deadcode - - errcheck - - gosimple - - govet - - ineffassign - - staticcheck - - structcheck - - typecheck - - unused - - varcheck - - depguard - - revive - - goimports - - unconvert - - scopelint - - maligned - - misspell - # - gocritic - - prealloc - #- gosec - diff --git a/services/storage-users/pkg/command/uploads.go b/services/storage-users/pkg/command/uploads.go index 0aa7174c348..ea553de0137 100644 --- a/services/storage-users/pkg/command/uploads.go +++ b/services/storage-users/pkg/command/uploads.go @@ -19,8 +19,9 @@ import ( func Uploads(cfg *config.Config) *cli.Command { return &cli.Command{ - Name: "uploads", - Usage: "manage uploads", + Name: "uploads", + Usage: "manage unfinished uploads", + Category: "maintenance", Before: func(c *cli.Context) error { if err := parser.ParseConfig(cfg); err != nil { fmt.Printf("%v", err) @@ -38,9 +39,8 @@ func Uploads(cfg *config.Config) *cli.Command { // ListUploads prints a list of all incomplete uploads func ListUploads(cfg *config.Config) *cli.Command { return &cli.Command{ - Name: "list", - Usage: fmt.Sprintf("Print a list of all incomplete uploads"), - Category: "services", + Name: "list", + Usage: "Print a list of all incomplete uploads", Before: func(c *cli.Context) error { err := parser.ParseConfig(cfg) if err != nil { @@ -85,9 +85,8 @@ func ListUploads(cfg *config.Config) *cli.Command { // PurgeExpiredUploads is the entry point for the server command. func PurgeExpiredUploads(cfg *config.Config) *cli.Command { return &cli.Command{ - Name: "purge", - Usage: fmt.Sprintf("Let %s extension clean up leftovers from expired downloads", cfg.Service.Name), - Category: "services", + Name: "clean", + Usage: "Clean up leftovers from expired uploads", Before: func(c *cli.Context) error { err := parser.ParseConfig(cfg) if err != nil { @@ -111,7 +110,7 @@ func PurgeExpiredUploads(cfg *config.Config) *cli.Command { managingFS, ok := fs.(storage.UploadsManager) if !ok { - fmt.Fprintf(os.Stderr, "'%s' storage does not support purging expired uploads\n", cfg.Driver) + fmt.Fprintf(os.Stderr, "'%s' storage does not support clean expired uploads\n", cfg.Driver) os.Exit(1) } @@ -119,11 +118,10 @@ func PurgeExpiredUploads(cfg *config.Config) *cli.Command { wg.Add(1) purgedChannel := make(chan tusd.FileInfo) + fmt.Println("Cleaned uploads:") go func() { for purged := range purgedChannel { - fmt.Printf("Purging %s (Filename: %s, Size: %d, Expires: %s)\n", - purged.ID, purged.MetaData["filename"], purged.Size, expiredString(purged.MetaData["expires"])) - + fmt.Printf(" - %s (%s, Size: %d, Expires: %s)\n", purged.ID, purged.MetaData["filename"], purged.Size, expiredString(purged.MetaData["expires"])) } wg.Done() }() @@ -132,7 +130,7 @@ func PurgeExpiredUploads(cfg *config.Config) *cli.Command { close(purgedChannel) wg.Wait() if err != nil { - fmt.Fprintf(os.Stderr, "Failed to purge expired uploads '%s'\n", err) + fmt.Fprintf(os.Stderr, "Failed to clean expired uploads '%s'\n", err) return err } return nil diff --git a/services/store/.golangci.yaml b/services/store/.golangci.yaml deleted file mode 100644 index 85a4bf3feb6..00000000000 --- a/services/store/.golangci.yaml +++ /dev/null @@ -1,29 +0,0 @@ -issues: - exclude-rules: - - path: pkg/proto/v0 - text: "SA1019:" - linters: - - staticcheck -linters: - enable: - - bodyclose - - deadcode - - errcheck - - gosimple - - govet - - ineffassign - - staticcheck - - structcheck - - typecheck - - unused - - varcheck - - depguard - - revive - - goimports - - unconvert - - scopelint - - maligned - - misspell - - gocritic - - prealloc - #- gosec diff --git a/sonar-project.properties b/sonar-project.properties index 3b8fe3f80d1..7eac08a8678 100644 --- a/sonar-project.properties +++ b/sonar-project.properties @@ -2,7 +2,7 @@ sonar.projectKey=owncloud_ocis sonar.organization=owncloud-1 sonar.projectName=ocis -sonar.projectVersion=2.0.0-beta.5 +sonar.projectVersion=2.0.0-beta.6 sonar.host.url=https://sonarcloud.io # ===================================================== @@ -33,7 +33,7 @@ sonar.go.coverage.reportPaths=cache/coverage/* # golangci-lint does not support wildcard # https://github.com/SonarSource/slang/blob/85b05160bc1b31c6072a35f8818da4376b107afa/sonar-go-plugin/src/main/java/org/sonar/go/externalreport/GolangCILintReportSensor.java#L37 # https://github.com/SonarSource/slang/blob/85b05160bc1b31c6072a35f8818da4376b107afa/sonar-go-plugin/src/main/java/org/sonar/go/externalreport/AbstractReportSensor.java#L76-L90 -sonar.go.golangci-lint.reportPaths=cache/checkstyle/accounts_checkstyle.xml,cache/checkstyle/audit_checkstyle.xml,cache/checkstyle/glauth_checkstyle.xml,cache/checkstyle/graph_checkstyle.xml,cache/checkstyle/graph-explorer_checkstyle.xml,cache/checkstyle/idm_checkstyle.xml,cache/checkstyle/idp_checkstyle.xml,cache/checkstyle/nats_checkstyle.xml,cache/checkstyle/notifications_checkstyle.xml,cache/checkstyle/ocis_checkstyle.xml,cache/checkstyle/ocis-pkg_checkstyle.xml,cache/checkstyle/ocs_checkstyle.xml,cache/checkstyle/proxy_checkstyle.xml,cache/checkstyle/settings_checkstyle.xml,cache/checkstyle/storage_checkstyle.xml,cache/checkstyle/store_checkstyle.xml,cache/checkstyle/thumbnails_checkstyle.xml,cache/checkstyle/web_checkstyle.xml,cache/checkstyle/webdav_checkstyle.xml +sonar.go.golangci-lint.reportPaths=cache/checkstyle/app-provider_checkstyle.xml,cache/checkstyle/app-registry_checkstyle.xml,cache/checkstyle/audit_checkstyle.xml,cache/checkstyle/auth-basic_checkstyle.xml,cache/checkstyle/auth-bearer_checkstyle.xml,cache/checkstyle/auth-machine_checkstyle.xml,cache/checkstyle/frontend_checkstyle.xml,cache/checkstyle/gateway_checkstyle.xml,cache/checkstyle/graph_checkstyle.xml,cache/checkstyle/graph-explorer_checkstyle.xml,cache/checkstyle/groups_checkstyle.xml,cache/checkstyle/idm_checkstyle.xml,cache/checkstyle/idp_checkstyle.xml,cache/checkstyle/nats_checkstyle.xml,cache/checkstyle/notifications_checkstyle.xml,cache/checkstyle/ocdav_checkstyle.xml,cache/checkstyle/ocs_checkstyle.xml,cache/checkstyle/proxy_checkstyle.xml,cache/checkstyle/search_checkstyle.xml,cache/checkstyle/settings_checkstyle.xml,cache/checkstyle/sharing_checkstyle.xml,cache/checkstyle/storage-publiclink_checkstyle.xml,cache/checkstyle/storage-shares_checkstyle.xml,cache/checkstyle/storage-system_checkstyle.xml,cache/checkstyle/storage-users_checkstyle.xml,cache/checkstyle/store_checkstyle.xml,cache/checkstyle/thumbnails_checkstyle.xml,cache/checkstyle/users_checkstyle.xml,cache/checkstyle/web_checkstyle.xml,cache/checkstyle/webdav_checkstyle.xml # Exclude files sonar.exclusions=**/third_party,docs/**,changelog/**,*/pkg/assets/embed.go,idp/assets/identifier/**,**/package.json,**/rollup.config.js,CHANGELOG.md,**/pkg/proto/**/*.pb.*,deployments/**,tests/**,vendor-bin/**,README.md,**/mocks/ diff --git a/tests/acceptance/expected-failures-API-on-OCIS-storage.md b/tests/acceptance/expected-failures-API-on-OCIS-storage.md index eef202227cd..7da96c76e19 100644 --- a/tests/acceptance/expected-failures-API-on-OCIS-storage.md +++ b/tests/acceptance/expected-failures-API-on-OCIS-storage.md @@ -8,10 +8,10 @@ Basic file management like up and download, move, copy, properties, trash, versi #### [Getting information about a folder overwritten by a file gives 500 error instead of 404](https://github.com/owncloud/ocis/issues/1239) -- [apiWebdavProperties1/copyFile.feature:286](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavProperties1/copyFile.feature#L286) -- [apiWebdavProperties1/copyFile.feature:287](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavProperties1/copyFile.feature#L287) -- [apiWebdavProperties1/copyFile.feature:309](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavProperties1/copyFile.feature#L309) -- [apiWebdavProperties1/copyFile.feature:310](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavProperties1/copyFile.feature#L310) +- [apiWebdavProperties1/copyFile.feature:276](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavProperties1/copyFile.feature#L276) +- [apiWebdavProperties1/copyFile.feature:277](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavProperties1/copyFile.feature#L277) +- [apiWebdavProperties1/copyFile.feature:294](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavProperties1/copyFile.feature#L294) +- [apiWebdavProperties1/copyFile.feature:295](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavProperties1/copyFile.feature#L295) #### [Custom dav properties with namespaces are rendered incorrectly](https://github.com/owncloud/ocis/issues/2140) @@ -55,8 +55,8 @@ Synchronization features like etag propagation, setting mtime and locking files #### [Uploading an old method chunked file with checksum should fail using new DAV path](https://github.com/owncloud/ocis/issues/2323) -- [apiMain/checksums.feature:381](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiMain/checksums.feature#L381) -- [apiMain/checksums.feature:386](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiMain/checksums.feature#L386) +- [apiMain/checksums.feature:371](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiMain/checksums.feature#L371) +- [apiMain/checksums.feature:376](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiMain/checksums.feature#L376) #### [Webdav LOCK operations](https://github.com/owncloud/ocis/issues/1284) @@ -581,9 +581,8 @@ cannot share a folder with create permission #### [changing user quota gives ocs status 103 / Cannot set quota](https://github.com/owncloud/product/issues/247) -- [apiShareOperationsToShares2/uploadToShare.feature:245](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiShareOperationsToShares2/uploadToShare.feature#L245) -- [apiShareOperationsToShares2/uploadToShare.feature:246](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiShareOperationsToShares2/uploadToShare.feature#L246) -- [apiShareOperationsToShares2/uploadToShare.feature:251](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiShareOperationsToShares2/uploadToShare.feature#L251) +- [apiShareOperationsToShares2/uploadToShare.feature:210](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiShareOperationsToShares2/uploadToShare.feature#L210) +- [apiShareOperationsToShares2/uploadToShare.feature:211](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiShareOperationsToShares2/uploadToShare.feature#L211) #### [not possible to move file into a received folder](https://github.com/owncloud/ocis/issues/764) @@ -943,42 +942,6 @@ And other missing implementation of favorites - [apiFavorites/favoritesSharingToShares.feature:67](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiFavorites/favoritesSharingToShares.feature#L67) - [apiFavorites/favoritesSharingToShares.feature:83](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiFavorites/favoritesSharingToShares.feature#L83) - [apiFavorites/favoritesSharingToShares.feature:108](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiFavorites/favoritesSharingToShares.feature#L108) -- [apiMain/checksums.feature:211](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiMain/checksums.feature#L211) -- [apiShareOperationsToShares2/getWebDAVSharePermissions.feature:51](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiShareOperationsToShares2/getWebDAVSharePermissions.feature#L51) -- [apiShareOperationsToShares2/getWebDAVSharePermissions.feature:78](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiShareOperationsToShares2/getWebDAVSharePermissions.feature#L78) -- [apiShareOperationsToShares2/getWebDAVSharePermissions.feature:98](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiShareOperationsToShares2/getWebDAVSharePermissions.feature#L98) -- [apiShareOperationsToShares2/getWebDAVSharePermissions.feature:125](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiShareOperationsToShares2/getWebDAVSharePermissions.feature#L125) -- [apiShareOperationsToShares2/getWebDAVSharePermissions.feature:145](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiShareOperationsToShares2/getWebDAVSharePermissions.feature#L145) -- [apiShareOperationsToShares2/getWebDAVSharePermissions.feature:172](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiShareOperationsToShares2/getWebDAVSharePermissions.feature#L172) -- [apiShareOperationsToShares2/getWebDAVSharePermissions.feature:212](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiShareOperationsToShares2/getWebDAVSharePermissions.feature#L212) -- [apiShareOperationsToShares2/getWebDAVSharePermissions.feature:238](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiShareOperationsToShares2/getWebDAVSharePermissions.feature#L238) -- [apiShareOperationsToShares2/getWebDAVSharePermissions.feature:258](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiShareOperationsToShares2/getWebDAVSharePermissions.feature#L258) -- [apiShareOperationsToShares2/getWebDAVSharePermissions.feature:285](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiShareOperationsToShares2/getWebDAVSharePermissions.feature#L285) -- [apiShareOperationsToShares2/getWebDAVSharePermissions.feature:305](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiShareOperationsToShares2/getWebDAVSharePermissions.feature#L305) -- [apiShareOperationsToShares2/getWebDAVSharePermissions.feature:332](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiShareOperationsToShares2/getWebDAVSharePermissions.feature#L332) -- [apiShareOperationsToShares2/getWebDAVSharePermissions.feature:352](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiShareOperationsToShares2/getWebDAVSharePermissions.feature#L352) -- [apiShareOperationsToShares2/getWebDAVSharePermissions.feature:379](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiShareOperationsToShares2/getWebDAVSharePermissions.feature#L379) -- [apiShareOperationsToShares2/getWebDAVSharePermissions.feature:399](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiShareOperationsToShares2/getWebDAVSharePermissions.feature#L399) -- [apiShareOperationsToShares2/getWebDAVSharePermissions.feature:426](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiShareOperationsToShares2/getWebDAVSharePermissions.feature#L426) -- [apiShareOperationsToShares2/uploadToShare.feature:47](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiShareOperationsToShares2/uploadToShare.feature#L47) -- [apiShareOperationsToShares2/uploadToShare.feature:78](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiShareOperationsToShares2/uploadToShare.feature#L78) -- [apiShareOperationsToShares2/uploadToShare.feature:111](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiShareOperationsToShares2/uploadToShare.feature#L111) -- [apiShareOperationsToShares2/uploadToShare.feature:140](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiShareOperationsToShares2/uploadToShare.feature#L140) -- [apiShareOperationsToShares2/uploadToShare.feature:171](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiShareOperationsToShares2/uploadToShare.feature#L171) -- [apiShareOperationsToShares2/uploadToShare.feature:346](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiShareOperationsToShares2/uploadToShare.feature#L346) -- [apiShareOperationsToShares2/uploadToShare.feature:347](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiShareOperationsToShares2/uploadToShare.feature#L347) -- [apiWebdavProperties1/copyFile.feature:89](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavProperties1/copyFile.feature#L89) -- [apiWebdavProperties1/copyFile.feature:116](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavProperties1/copyFile.feature#L116) -- [apiWebdavProperties1/copyFile.feature:292](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavProperties1/copyFile.feature#L292) -- [apiWebdavProperties1/copyFile.feature:315](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavProperties1/copyFile.feature#L315) -- [apiWebdavProperties1/copyFile.feature:343](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavProperties1/copyFile.feature#L343) -- [apiWebdavProperties1/copyFile.feature:373](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavProperties1/copyFile.feature#L373) -- [apiWebdavProperties1/copyFile.feature:402](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavProperties1/copyFile.feature#L402) -- [apiWebdavProperties1/copyFile.feature:431](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavProperties1/copyFile.feature#L431) -- [apiWebdavProperties1/copyFile.feature:515](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavProperties1/copyFile.feature#L515) -- [apiWebdavProperties1/copyFile.feature:548](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavProperties1/copyFile.feature#L548) -- [apiWebdavProperties1/copyFile.feature:580](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavProperties1/copyFile.feature#L580) -- [apiWebdavProperties1/copyFile.feature:612](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavProperties1/copyFile.feature#L612) - [apiWebdavUploadTUS/uploadToShare.feature:31](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavUploadTUS/uploadToShare.feature#L31) - [apiWebdavUploadTUS/uploadToShare.feature:50](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavUploadTUS/uploadToShare.feature#L50) - [apiWebdavUploadTUS/uploadToShare.feature:72](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavUploadTUS/uploadToShare.feature#L72) @@ -1187,12 +1150,12 @@ And other missing implementation of favorites #### [copying the file inside Shares folder returns 404](https://github.com/owncloud/ocis/issues/3874) -- [apiWebdavProperties1/copyFile.feature:452](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavProperties1/copyFile.feature#L452) -- [apiWebdavProperties1/copyFile.feature:453](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavProperties1/copyFile.feature#L453) -- [apiWebdavProperties1/copyFile.feature:458](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavProperties1/copyFile.feature#L458) -- [apiWebdavProperties1/copyFile.feature:478](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavProperties1/copyFile.feature#L478) -- [apiWebdavProperties1/copyFile.feature:479](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavProperties1/copyFile.feature#L479) -- [apiWebdavProperties1/copyFile.feature:484](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavProperties1/copyFile.feature#L484) +- [apiWebdavProperties1/copyFile.feature:412](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavProperties1/copyFile.feature#L412) +- [apiWebdavProperties1/copyFile.feature:413](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavProperties1/copyFile.feature#L413) +- [apiWebdavProperties1/copyFile.feature:418](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavProperties1/copyFile.feature#L418) +- [apiWebdavProperties1/copyFile.feature:438](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavProperties1/copyFile.feature#L438) +- [apiWebdavProperties1/copyFile.feature:439](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavProperties1/copyFile.feature#L439) +- [apiWebdavProperties1/copyFile.feature:444](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavProperties1/copyFile.feature#L444) ### Won't fix @@ -1215,9 +1178,9 @@ Not everything needs to be implemented for ocis. While the oc10 testsuite covers #### [Blacklist files extensions](https://github.com/owncloud/ocis/issues/2177) -- [apiWebdavProperties1/copyFile.feature:132](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavProperties1/copyFile.feature#L132) -- [apiWebdavProperties1/copyFile.feature:133](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavProperties1/copyFile.feature#L133) -- [apiWebdavProperties1/copyFile.feature:138](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavProperties1/copyFile.feature#L138) +- [apiWebdavProperties1/copyFile.feature:122](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavProperties1/copyFile.feature#L122) +- [apiWebdavProperties1/copyFile.feature:123](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavProperties1/copyFile.feature#L123) +- [apiWebdavProperties1/copyFile.feature:128](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavProperties1/copyFile.feature#L128) - [apiWebdavProperties1/createFolder.feature:95](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavProperties1/createFolder.feature#L95) - [apiWebdavProperties1/createFolder.feature:96](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavProperties1/createFolder.feature#L96) - [apiWebdavProperties1/createFolder.feature:101](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavProperties1/createFolder.feature#L101) @@ -1375,10 +1338,6 @@ Not everything needs to be implemented for ocis. While the oc10 testsuite covers - [apiWebdavOperations/listFiles.feature:256](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavOperations/listFiles.feature#L256) - [apiWebdavOperations/listFiles.feature:293](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavOperations/listFiles.feature#L293) -#### [Trying to modify a shared file using spaces end-point returns 409 HTTP status code](https://github.com/owncloud/ocis/issues/3241) - -- [apiMain/checksums.feature:233](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiMain/checksums.feature#L233) - ### [graph/users: enable/disable users](https://github.com/owncloud/ocis/issues/3064) - [apiWebdavOperations/refuseAccess.feature:35](https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiWebdavOperations/refuseAccess.feature#L35) diff --git a/tests/acceptance/features/apiSpaces/copySpaces.feature b/tests/acceptance/features/apiSpaces/copySpaces.feature index 3d0cfa13d05..5f2768fe270 100644 --- a/tests/acceptance/features/apiSpaces/copySpaces.feature +++ b/tests/acceptance/features/apiSpaces/copySpaces.feature @@ -437,7 +437,7 @@ Feature: copy file Scenario Outline: User copies a folder from space shares jail with different role to space project with role viewer Given the administrator has given "Brian" the role "Space Admin" using the settings api And user "Brian" has created a space "Project" with the default quota using the GraphApi - And user "Brian" has shared a space "Project" to user "Alice" with role "" + And user "Brian" has shared a space "Project" to user "Alice" with role "viewer" And user "Brian" has created folder "/testshare" And user "Brian" has created folder "/testshare/folder1" And user "Brian" has uploaded file with content "testshare content" to "/testshare/folder1/testshare.txt" @@ -450,4 +450,4 @@ Feature: copy file Examples: | permissions | | 31 | - | 17 | \ No newline at end of file + | 17 | diff --git a/tests/acceptance/features/apiSpaces/editPublicLinkOfSpace.feature b/tests/acceptance/features/apiSpaces/editPublicLinkOfSpace.feature index 764d0f63e5f..29e4a96f902 100644 --- a/tests/acceptance/features/apiSpaces/editPublicLinkOfSpace.feature +++ b/tests/acceptance/features/apiSpaces/editPublicLinkOfSpace.feature @@ -52,18 +52,18 @@ Feature: A manager of the space can edit public link | 15 | read,update,create,delete | | newName | 2042-03-25T23:59:59+0100 | - Scenario Outline: Only users with manager role can see a created public link + Scenario Outline: All members can see a created public link Given using OCS API version "2" When user "Alice" shares a space "edit space" to user "Brian" with role "" Then the HTTP status code should be "200" And the OCS status code should be "200" And for user "Alice" the space "edit space" should contain the last created public link - And for user "Brian" the space "edit space" contain the last created public link + And for user "Brian" the space "edit space" should contain the last created public link Examples: - | role | shouldOrNot | - | manager | should | - | editor | should | - | viewer | should | + | role | + | manager | + | editor | + | viewer | Scenario Outline: Members of the space try to edit a public link diff --git a/tests/acceptance/features/apiSpaces/moveSpaces.feature b/tests/acceptance/features/apiSpaces/moveSpaces.feature index 355dbe24353..6d34fd37fa2 100644 --- a/tests/acceptance/features/apiSpaces/moveSpaces.feature +++ b/tests/acceptance/features/apiSpaces/moveSpaces.feature @@ -33,7 +33,7 @@ Feature: move (rename) file And user "Brian" has created a space "Project" with the default quota using the GraphApi And user "Brian" has created a folder "newfolder" in space "Project" And user "Brian" has uploaded a file inside space "Project" with content "some content" to "insideSpace.txt" - And user "Brian" has shared a space "Project" to user "Alice" with role "" + And user "Brian" has shared a space "Project" to user "Alice" with role "viewer" When user "Alice" moves file "insideSpace.txt" to "newfolder/insideSpace.txt" in space "Project" using the WebDAV API Then the HTTP status code should be "403" And for user "Alice" the space "Project" should not contain these entries: diff --git a/tests/acceptance/features/apiSpaces/shareOperations.feature b/tests/acceptance/features/apiSpaces/shareOperations.feature new file mode 100644 index 00000000000..e536f3d394c --- /dev/null +++ b/tests/acceptance/features/apiSpaces/shareOperations.feature @@ -0,0 +1,227 @@ +@api @skipOnOcV10 +Feature: sharing + + Background: + Given using OCS API version "1" + And these users have been created with default attributes and without skeleton files: + | username | + | Alice | + | Brian | + And using spaces DAV path + + + Scenario: Correct webdav share-permissions for received file with edit and reshare permissions + Given user "Alice" has uploaded file with content "foo" to "/tmp.txt" + And user "Alice" has shared file "/tmp.txt" with user "Brian" + And user "Brian" has accepted share "/tmp.txt" offered by user "Alice" + When user "Brian" gets the following properties of file "/tmp.txt" inside space "Shares Jail" using the WebDAV API + | propertyName | + | ocs:share-permissions | + Then the HTTP status code should be "207" + And the single response should contain a property "ocs:share-permissions" with value "19" + + + Scenario: Correct webdav share-permissions for received group shared file with edit and reshare permissions + Given group "grp1" has been created + And user "Brian" has been added to group "grp1" + And user "Alice" has uploaded file with content "foo" to "/tmp.txt" + And user "Alice" has created a share with settings + | path | /tmp.txt | + | shareType | group | + | permissions | share,update,read | + | shareWith | grp1 | + And user "Brian" has accepted share "/tmp.txt" offered by user "Alice" + When user "Brian" gets the following properties of file "/tmp.txt" inside space "Shares Jail" using the WebDAV API + | propertyName | + | ocs:share-permissions | + Then the HTTP status code should be "207" + And the single response should contain a property "ocs:share-permissions" with value "19" + + + Scenario: Correct webdav share-permissions for received file with edit permissions but no reshare permissions + Given user "Alice" has uploaded file with content "foo" to "/tmp.txt" + And user "Alice" has shared file "tmp.txt" with user "Brian" + And user "Brian" has accepted share "/tmp.txt" offered by user "Alice" + When user "Alice" updates the last share using the sharing API with + | permissions | update,read | + Then the HTTP status code should be "200" + And as user "Brian" file "/tmp.txt" inside space "Shares Jail" should contain a property "ocs:share-permissions" with value "3" + + + Scenario: Correct webdav share-permissions for received group shared file with edit permissions but no reshare permissions + Given group "grp1" has been created + And user "Brian" has been added to group "grp1" + And user "Alice" has uploaded file with content "foo" to "/tmp.txt" + And user "Alice" has created a share with settings + | path | /tmp.txt | + | shareType | group | + | permissions | update,read | + | shareWith | grp1 | + And user "Brian" has accepted share "/tmp.txt" offered by user "Alice" + When user "Brian" gets the following properties of file "/tmp.txt" inside space "Shares Jail" using the WebDAV API + | propertyName | + | ocs:share-permissions | + Then the HTTP status code should be "207" + And the single response should contain a property "ocs:share-permissions" with value "3" + + + Scenario: Correct webdav share-permissions for received file with reshare permissions but no edit permissions + Given user "Alice" has uploaded file with content "foo" to "/tmp.txt" + And user "Alice" has shared file "tmp.txt" with user "Brian" + And user "Brian" has accepted share "/tmp.txt" offered by user "Alice" + When user "Alice" updates the last share using the sharing API with + | permissions | share,read | + Then the HTTP status code should be "200" + And as user "Brian" file "/tmp.txt" inside space "Shares Jail" should contain a property "ocs:share-permissions" with value "17" + + + Scenario: Correct webdav share-permissions for received group shared file with reshare permissions but no edit permissions + Given group "grp1" has been created + And user "Brian" has been added to group "grp1" + And user "Alice" has uploaded file with content "foo" to "/tmp.txt" + And user "Alice" has created a share with settings + | path | /tmp.txt | + | shareType | group | + | permissions | share,read | + | shareWith | grp1 | + And user "Brian" has accepted share "/tmp.txt" offered by user "Alice" + When user "Brian" gets the following properties of file "/tmp.txt" inside space "Shares Jail" using the WebDAV API + | propertyName | + | ocs:share-permissions | + Then the HTTP status code should be "207" + And the single response should contain a property "ocs:share-permissions" with value "17" + + + Scenario: Correct webdav share-permissions for received folder with all permissions + Given user "Alice" has created folder "/tmp" + And user "Alice" has shared file "/tmp" with user "Brian" + And user "Brian" has accepted share "/tmp" offered by user "Alice" + When user "Brian" gets the following properties of folder "/tmp" inside space "Shares Jail" using the WebDAV API + | propertyName | + | ocs:share-permissions | + Then the HTTP status code should be "207" + And the single response should contain a property "ocs:share-permissions" with value "31" + + + Scenario: Correct webdav share-permissions for received group shared folder with all permissions + Given group "grp1" has been created + And user "Brian" has been added to group "grp1" + And user "Alice" has created folder "/tmp" + And user "Alice" has created a share with settings + | path | tmp | + | shareType | group | + | shareWith | grp1 | + And user "Brian" has accepted share "/tmp" offered by user "Alice" + When user "Brian" gets the following properties of folder "/tmp" inside space "Shares Jail" using the WebDAV API + | propertyName | + | ocs:share-permissions | + Then the HTTP status code should be "207" + And the single response should contain a property "ocs:share-permissions" with value "31" + + + Scenario: Correct webdav share-permissions for received folder with all permissions but edit + Given user "Alice" has created folder "/tmp" + And user "Alice" has shared file "/tmp" with user "Brian" + And user "Brian" has accepted share "/tmp" offered by user "Alice" + When user "Alice" updates the last share using the sharing API with + | permissions | share,delete,create,read | + Then the HTTP status code should be "200" + And as user "Brian" folder "/tmp" inside space "Shares Jail" should contain a property "ocs:share-permissions" with value "29" + + + Scenario: Correct webdav share-permissions for received group shared folder with all permissions but edit + Given group "grp1" has been created + And user "Brian" has been added to group "grp1" + And user "Alice" has created folder "/tmp" + And user "Alice" has created a share with settings + | path | tmp | + | shareType | group | + | shareWith | grp1 | + | permissions | share,delete,create,read | + And user "Brian" has accepted share "/tmp" offered by user "Alice" + When user "Brian" gets the following properties of folder "/tmp" inside space "Shares Jail" using the WebDAV API + | propertyName | + | ocs:share-permissions | + Then the HTTP status code should be "207" + And the single response should contain a property "ocs:share-permissions" with value "29" + + + Scenario: Correct webdav share-permissions for received folder with all permissions but create + Given user "Alice" has created folder "/tmp" + And user "Alice" has shared file "/tmp" with user "Brian" + And user "Brian" has accepted share "/tmp" offered by user "Alice" + When user "Alice" updates the last share using the sharing API with + | permissions | share,delete,update,read | + Then the HTTP status code should be "200" + And as user "Brian" folder "/tmp" inside space "Shares Jail" should contain a property "ocs:share-permissions" with value "27" + + + Scenario: Correct webdav share-permissions for received group shared folder with all permissions but create + Given group "grp1" has been created + And user "Brian" has been added to group "grp1" + And user "Alice" has created folder "/tmp" + And user "Alice" has created a share with settings + | path | tmp | + | shareType | group | + | shareWith | grp1 | + | permissions | share,delete,update,read | + And user "Brian" has accepted share "/tmp" offered by user "Alice" + When user "Brian" gets the following properties of folder "/tmp" inside space "Shares Jail" using the WebDAV API + | propertyName | + | ocs:share-permissions | + Then the HTTP status code should be "207" + And the single response should contain a property "ocs:share-permissions" with value "27" + + + Scenario: Correct webdav share-permissions for received folder with all permissions but delete + Given user "Alice" has created folder "/tmp" + And user "Alice" has shared file "/tmp" with user "Brian" + And user "Brian" has accepted share "/tmp" offered by user "Alice" + When user "Alice" updates the last share using the sharing API with + | permissions | share,create,update,read | + Then the HTTP status code should be "200" + And as user "Brian" folder "/tmp" inside space "Shares Jail" should contain a property "ocs:share-permissions" with value "23" + + + Scenario: Correct webdav share-permissions for received group shared folder with all permissions but delete + Given group "grp1" has been created + And user "Brian" has been added to group "grp1" + And user "Alice" has created folder "/tmp" + And user "Alice" has created a share with settings + | path | tmp | + | shareType | group | + | shareWith | grp1 | + | permissions | share,create,update,read | + And user "Brian" has accepted share "/tmp" offered by user "Alice" + When user "Brian" gets the following properties of folder "/tmp" inside space "Shares Jail" using the WebDAV API + | propertyName | + | ocs:share-permissions | + Then the HTTP status code should be "207" + And the single response should contain a property "ocs:share-permissions" with value "23" + + + Scenario: Correct webdav share-permissions for received folder with all permissions but share + Given user "Alice" has created folder "/tmp" + And user "Alice" has shared file "/tmp" with user "Brian" + And user "Brian" has accepted share "/tmp" offered by user "Alice" + When user "Alice" updates the last share using the sharing API with + | permissions | change | + Then the HTTP status code should be "200" + And as user "Brian" folder "/tmp" inside space "Shares Jail" should contain a property "ocs:share-permissions" with value "15" + + + Scenario: Correct webdav share-permissions for received group shared folder with all permissions but share + Given group "grp1" has been created + And user "Brian" has been added to group "grp1" + And user "Alice" has created folder "/tmp" + And user "Alice" has created a share with settings + | path | tmp | + | shareType | group | + | shareWith | grp1 | + | permissions | change | + And user "Brian" has accepted share "/tmp" offered by user "Alice" + When user "Brian" gets the following properties of folder "/tmp" inside space "Shares Jail" using the WebDAV API + | propertyName | + | ocs:share-permissions | + Then the HTTP status code should be "207" + And the single response should contain a property "ocs:share-permissions" with value "15" \ No newline at end of file diff --git a/tests/acceptance/features/apiSpaces/shareSubItemOfSpace.feature b/tests/acceptance/features/apiSpaces/shareSubItemOfSpace.feature index 4a22178e1ff..184fae7da6b 100644 --- a/tests/acceptance/features/apiSpaces/shareSubItemOfSpace.feature +++ b/tests/acceptance/features/apiSpaces/shareSubItemOfSpace.feature @@ -62,3 +62,15 @@ Feature: Share a file or folder that is inside a space | file.txt | editor | 404 | No share permission | | file.txt | viewer | 404 | No share permission | | folder | viewer | 404 | No share permission | + + + Scenario Outline: An user participant of the project space can see the created resources share + Given user "Alice" has shared a space "share sub-item" to user "Brian" with role "" + When user "Alice" shares the following entity "file.txt" inside of space "share sub-item" with user "Bob" with role "editor" + Then for user "Alice" the space "share sub-item" should contain the last created share of the file "file.txt" + And for user "Brian" the space "share sub-item" should contain the last created share of the file "file.txt" + Examples: + | spaceRole | + | editor | + | viewer | + | manager | diff --git a/tests/acceptance/features/apiSpaces/shareSubItemOfSpaceViaPublicLink.feature b/tests/acceptance/features/apiSpaces/shareSubItemOfSpaceViaPublicLink.feature index 017ef55b9ae..e9bb47d8af2 100644 --- a/tests/acceptance/features/apiSpaces/shareSubItemOfSpaceViaPublicLink.feature +++ b/tests/acceptance/features/apiSpaces/shareSubItemOfSpaceViaPublicLink.feature @@ -117,3 +117,17 @@ Feature: Share a file or folder that is inside a space via public link | ocs_api_version | ocs_status_code | | 1 | 100 | | 2 | 200 | + + + Scenario Outline: An user participant of the project space can see the created public resources link + Given user "Alice" has shared a space "share sub-item" to user "Brian" with role "" + When user "Alice" creates a public link share inside of space "share sub-item" with settings: + | path | folder/file.txt | + | shareType | 3 | + | permissions | 1 | + Then for user "Brian" the space "share sub-item" should contain the last created public link of the file "folder/file.txt" + Examples: + | spaceRole | + | editor | + | viewer | + | manager | diff --git a/tests/acceptance/features/bootstrap/SpacesContext.php b/tests/acceptance/features/bootstrap/SpacesContext.php index 9548d0f6374..470a9d0fd9b 100644 --- a/tests/acceptance/features/bootstrap/SpacesContext.php +++ b/tests/acceptance/features/bootstrap/SpacesContext.php @@ -28,6 +28,7 @@ use Behat\Gherkin\Node\TableNode; use GuzzleHttp\Exception\GuzzleException; use Psr\Http\Message\ResponseInterface; use TestHelpers\HttpRequestHelper; +use TestHelpers\WebDavHelper; use TestHelpers\SetupHelper; use TestHelpers\GraphHelper; use PHPUnit\Framework\Assert; @@ -54,6 +55,11 @@ class SpacesContext implements Context { */ private TrashbinContext $trashbinContext; + /** + * @var WebDavPropertiesContext + */ + private WebDavPropertiesContext $webDavPropertiesContext; + /** * @var string */ @@ -370,6 +376,20 @@ class SpacesContext implements Context { throw new Exception(__METHOD__ . " user with name $userName not found"); } + /** + * using method from core to set share data + * + * @return void + */ + public function setLastShareData(): void { + // set last response as PublicShareData + $this->featureContext->setLastPublicShareData($this->featureContext->getResponseXml(null, __METHOD__)); + // set last shareId if ShareData exists + if (isset($this->featureContext->getLastPublicShareData()->data)) { + $this->featureContext->setLastPublicLinkShareId((string) $this->featureContext->getLastPublicShareData()->data[0]->id); + } + } + /** * @BeforeScenario * @@ -386,6 +406,7 @@ class SpacesContext implements Context { $this->featureContext = $environment->getContext('FeatureContext'); $this->ocsContext = $environment->getContext('OCSContext'); $this->trashbinContext = $environment->getContext('TrashbinContext'); + $this->webDavPropertiesContext = $environment->getContext('WebDavPropertiesContext'); // Run the BeforeScenario function in OCSContext to set it up correctly $this->ocsContext->before($scope); $this->baseUrl = \trim($this->featureContext->getBaseUrl(), "/"); @@ -1318,7 +1339,7 @@ class SpacesContext implements Context { ): array { $spaceId = $this->getResponseSpaceId(); //if we are using that step the second time in a scenario e.g. 'But ... should not' - //then don't parse the result again, because the result in a ResponseInterface + //then don't parse the result again, because the result is in a ResponseInterface if (empty($this->getResponseXml())) { $this->setResponseXml( HttpRequestHelper::parseResponseAsXml($this->featureContext->getResponse()) @@ -1989,6 +2010,10 @@ class SpacesContext implements Context { string $role ): void { $space = $this->getSpaceByName($user, $spaceName); + $availableRoleToAssignToShareSpace = ['manager', 'editor', 'viewer']; + if (!\in_array(\strtolower($role), $availableRoleToAssignToShareSpace)) { + throw new Error("The Selected " . $role . " Cannot be Found"); + } $body = [ "space_ref" => $space['id'], "shareType" => 7, @@ -1997,7 +2022,6 @@ class SpacesContext implements Context { ]; $fullUrl = $this->baseUrl . $this->ocsApiUrl; - $this->featureContext->setResponse( $this->sendPostRequestToUrl( $fullUrl, @@ -2045,6 +2069,7 @@ class SpacesContext implements Context { $body ) ); + $this->setLastShareData(); } /** @@ -2052,7 +2077,7 @@ class SpacesContext implements Context { * * @param string $user * @param string $spaceName - * @param TableNode|null $table + * @param TableNode $table * * @return void * @throws GuzzleException @@ -2060,7 +2085,7 @@ class SpacesContext implements Context { public function createPublicLinkToEntityInsideOfSpaceRequest( string $user, string $spaceName, - ?TableNode $table + TableNode $table ): void { $space = $this->getSpaceByName($user, $spaceName); $rows = $table->getRowsHash(); @@ -2091,6 +2116,32 @@ class SpacesContext implements Context { $body ) ); + + $this->setLastShareData(); + } + + /** + * @Given /^user "([^"]*)" has created a public link share inside of space "([^"]*)" with settings:$/ + * + * @param string $user + * @param string $spaceName + * @param TableNode $table + * + * @return void + * @throws GuzzleException + */ + public function userHasCreatedPublicLinkToEntityInsideOfSpaceRequest( + string $user, + string $spaceName, + TableNode $table + ): void { + $this->createPublicLinkToEntityInsideOfSpaceRequest($user, $spaceName, $table); + + $expectedHTTPStatus = "200"; + $this->featureContext->theHTTPStatusCodeShouldBe( + $expectedHTTPStatus, + "Expected response status code should be $expectedHTTPStatus" + ); } /** @@ -2111,7 +2162,6 @@ class SpacesContext implements Context { string $role ): void { $this->sendShareSpaceRequest($user, $spaceName, $userRecipient, $role); - $expectedHTTPStatus = "200"; $this->featureContext->theHTTPStatusCodeShouldBe( $expectedHTTPStatus, @@ -2908,12 +2958,7 @@ class SpacesContext implements Context { ) ); - // set last response as PublicShareData. using method from core - $this->featureContext->setLastPublicShareData($this->featureContext->getResponseXml(null, __METHOD__)); - // set last shareId if ShareData exists. using method from core - if (isset($this->featureContext->getLastPublicShareData()->data)) { - $this->featureContext->setLastPublicLinkShareId((string) $this->featureContext->getLastPublicShareData()->data[0]->id); - } + $this->setLastShareData(); } /** @@ -2943,10 +2988,13 @@ class SpacesContext implements Context { /** * @Then /^for user "([^"]*)" the space "([^"]*)" should (not|)\s?contain the last created public link$/ + * @Then /^for user "([^"]*)" the space "([^"]*)" should (not|)\s?contain the last created public link of the file "([^"]*)"$/ + * @Then /^for user "([^"]*)" the space "([^"]*)" should (not|)\s?contain the last created share of the file "([^"]*)"$/ * * @param string $user * @param string $spaceName * @param string $shouldOrNot (not|) + * @param string $fileName * * @return void * @@ -2955,10 +3003,18 @@ class SpacesContext implements Context { public function forUserSpaceShouldContainLinks( string $user, string $spaceName, - string $shouldOrNot + string $shouldOrNot, + string $fileName = '' ): void { - $space = $this->getSpaceByName($user, $spaceName); - $url = "/apps/files_sharing/api/v1/shares?reshares=true&space_ref=" . $space['id']; + $body = ''; + if (!empty ($fileName)) { + $body = $this->getFileId($user, $spaceName, $fileName); + } else { + $space = $this->getSpaceByName($user, $spaceName); + $body = $space['id']; + } + + $url = "/apps/files_sharing/api/v1/shares?reshares=true&space_ref=" . $body; $this->ocsContext->userSendsHTTPMethodToOcsApiEndpointWithBody( $user, @@ -2979,4 +3035,91 @@ class SpacesContext implements Context { Assert::assertEmpty($responseArray, __METHOD__ . ' Response should be empty'); } } + + /** + * @When /^user "([^"]*)" gets the following properties of (?:file|folder|entry|resource) "([^"]*)" inside space "([^"]*)" using the WebDAV API$/ + * + * @param string $user + * @param string $resourceName + * @param string $spaceName + * @param TableNode|null $propertiesTable + * + * @return void + * + * @throws Exception|GuzzleException + */ + public function userGetsTheFollowingPropertiesOfFileInsideSpaceUsingTheWebdavApi( + string $user, + string $resourceName, + string $spaceName, + TableNode $propertiesTable + ):void { + $space = $this->getSpaceByName($user, $spaceName); + $properties = null; + $fullUrl = $space["root"]["webDavUrl"] . '/' . ltrim($resourceName, "/"); + $this->featureContext->verifyTableNodeColumns($propertiesTable, ["propertyName"]); + $this->featureContext->verifyTableNodeColumnsCount($propertiesTable, 1); + if ($propertiesTable instanceof TableNode) { + foreach ($propertiesTable->getColumnsHash() as $row) { + $properties[] = $row["propertyName"]; + } + } + $body = WebDavHelper::getBodyForPropfind($properties); + $headers['Depth'] = '1'; + $this->featureContext->setResponse( + $this->sendPropfindRequestToUrl( + $fullUrl, + $user, + $this->featureContext->getPasswordForUser($user), + '', + $headers, + $body + ) + ); + $responseXml = $this->featureContext->getResponseXml(null, __METHOD__); + $this->featureContext->setResponseXmlObject($responseXml); + } + + /** + * @Then /^as user "([^"]*)" (?:file|folder|entry|resource) "([^"]*)" inside space "([^"]*)" should contain a property "([^"]*)" with value "([^"]*)"$/ + * + * @param string $user + * @param string $resourceName + * @param string $spaceName + * @param string $property + * @param string $expectedValue + * + * @return void + * + * @throws Exception|GuzzleException + */ + public function asUserFileInsideSpaceShouldContainAPropertyWithValue( + string $user, + string $resourceName, + string $spaceName, + string $property, + string $expectedValue + ):void { + $space = $this->getSpaceByName($user, $spaceName); + $fullUrl = $space["root"]["webDavUrl"] . '/' . ltrim($resourceName, "/"); + $body = WebDavHelper::getBodyForPropfind([$property]); + $headers['Depth'] = '1'; + $this->featureContext->setResponse( + $this->sendPropfindRequestToUrl( + $fullUrl, + $user, + $this->featureContext->getPasswordForUser($user), + '', + $headers, + $body + ) + ); + $responseXml = $this->featureContext->getResponseXml(null, __METHOD__); + $this->featureContext->setResponseXmlObject($responseXml); + $this->webDavPropertiesContext->checkSingleResponseContainsAPropertyWithValueAndAlternative( + $property, + $expectedValue, + $expectedValue + ); + } } diff --git a/tests/config/drone/check_web_cache.sh b/tests/config/drone/check_web_cache.sh index 6ef83fa5533..0226db5001c 100644 --- a/tests/config/drone/check_web_cache.sh +++ b/tests/config/drone/check_web_cache.sh @@ -3,7 +3,7 @@ source .drone.env echo "Checking web version - $WEB_COMMITID in cache" -URL="$CACHE_ENDPOINT/$CACHE_BUCKET/ocis/web-test-runner/$WEB_COMMITID/README.md" +URL="$CACHE_ENDPOINT/$CACHE_BUCKET/ocis/web-test-runner/$WEB_COMMITID/web.tar.gz" echo "Checking for the web cache at '$URL'."