Commit Graph

4151 Commits

Author SHA1 Message Date
Konstantin Schaper
7b933c6821 Improve plugin center error feedback and cache invalidation (#2147)
The plugin center cache was not invalidated when the proxy configuration was changed in the global settings. This caused stale and inconsistent state to be displayed to the user while there was no feedback that something was wrong.
2022-11-04 11:49:08 +01:00
René Pfeuffer
a009ce9397 Fix clone of git repositories with lfs files via ssh (#2144)
Cloning repositories with LFS data via ssh requires the creation of access tokens using a subject authenticated with an already scoped token (the first scoped token is created by the ssh lfs authentication command; with this token the further requests are issued which will create further tokens for the individual lfs download requests). This failed, because such a creation was rejected without further checks. Now we test, whether the requested scope is permitted by the current scope.
2022-10-28 10:31:47 +02:00
René Pfeuffer
54081ccdc6 Git import with lfs support (#2133)
This adds the possibility to load files managed by lfs to the repository import of git repositories.

Co-authored-by: Konstantin Schaper <konstantin.schaper@cloudogu.com>
2022-10-25 09:14:40 +02:00
Eduard Heimbuch
8db2e76ecc Resolve plugin installation conflict were the same plugin was tried to be installed multiple times for one single action. (#2138)
The pending queue is updated after all the plugins to be installed are collected, and then we already may have duplicate entries. Because of this we check right on the collecting step if the plugin was already added during this single action.
2022-10-20 20:38:58 +02:00
Konstantin Schaper
e99d77cb04 Upgrade Jackson to version 2.13.4 2022-10-17 17:27:36 +02:00
Konstantin Schaper
fe82c967b8 Fix creating a repository permission without a name breaking the repository (#2126)
If a POST request is submitted to the rest api for repostory permissions, the regex validator ignores the name field if it is null, which leads to an internal server error and breaks any further attempts to interact with that repository. An additional not-null constraint resolves this problem.
2022-09-30 10:27:41 +02:00
Florian Scholdei
89386928b6 Add feedback links to footer (#2125)
Add feedback links in "Support" section of the footer. The links refer to the creation of a new topic in the SCMM section of the forum.
2022-09-27 16:18:03 +02:00
Konstantin Schaper
74702591ed Revert "Add feedback form (#1967)"
This reverts commit 4407dc6d8a.

# Conflicts:
#	scm-ui/ui-api/src/config.ts
#	scm-ui/ui-api/src/index.ts
#	scm-ui/ui-webapp/public/locales/en/commons.json
#	scm-ui/ui-webapp/src/containers/App.tsx
#	scm-ui/ui-webapp/src/containers/Feedback.tsx
2022-09-27 10:27:08 +02:00
René Pfeuffer
35578985c9 Reduce the output from the realm trace log (#2121)
This reduces the amount of lines logged with log level
'trace' from the DefaultRealm. This is done by concatenating
the single permissions and roles in a single line.

A log with the new layout looks something like this (the [...]
would list all further permissions in the real log output):

TRACE sonia.scm.security.DefaultRealm - authorization summary:
username   : scmadmin
roles      : user
scope      :
permissions: repository:*:ChTG0dBeUH , group:autocomplete , repository:*:[...]

In contrast, with the old layout it looks like this:

TRACE sonia.scm.security.DefaultRealm - authorization summary:
username   : scmadmin
roles      :
 - user
scope      :
permissions:
 - repository:*:ChTG0dBeUH
 - group:autocomplete
 - repository:*:5DTFWwBTiY
 - repository:*:ASTGBIVz11D
 - user:changeApiKeys:scmadmin
 - user:changePassword:scmadmin
 - user:changePublicKeys:scmadmin
 - user:readAuthorizedKeys,writeAuthorizedKeys:scmadmin
 - *
 - user:read:scmadmin
 - user:autocomplete
 - repository:*:4rT7VPex5J
2022-09-14 14:35:35 +02:00
Eduard Heimbuch
6f2be13197 Introduce NoOpIndexReader to handle missing indexes without errors (#2113)
We stumbled upon errors accessing index from plugins which were not yet initialized. To prevent this errors we use our own No-Op IndexReader for missing indices.
2022-09-06 10:06:17 +02:00
Konstantin Schaper
4b92959b9c Revert introduction of tailwind (#2109)
After many days invested in making tailwind work in the SCM-Manager environment as well as a long discussion last week, we have decided not to move further with tailwind, but still keep adding new, independent modules for frontend components. Tailwind simply overcomplicated our build pipeline because bulma was already part of the api and the two were incompatible on several occasions. Styling will continue to be guided by bulma and all parts related to tailwind are removed. We therefore continue the trend of focusing on improving our existing stack rather than adding further complexity.
2022-08-29 10:23:40 +02:00
Konstantin Schaper
56ace2811b Implement reindex mechanism for search (#2104)
Adds a new button to repository settings to allow users to manually delete and re-create search indices. The actual re-indexing is happening in plugins that subscribe to the newly created event.

Co-authored-by: Eduard Heimbuch <eduard.heimbuch@cloudogu.com>
2022-08-17 13:22:34 +02:00
Eduard Heimbuch
e590a3ee68 Add changesets command to enable commit search (#2106)
Introduce changesets command to find all changesets for a single repository. This is required to index all changesets for the commit search.
2022-08-17 12:44:59 +02:00
Eduard Heimbuch
550ebefd93 Context sensitive search (#2102)
Extend global search to search context-sensitive in repositories and namespaces.
2022-08-04 12:14:46 +02:00
Konstantin Schaper
27dbcbf28d Integrate tailwind css and create new button library (#2098)
Introduce tailwind as new frontend styling library to replace bulma in the longer run. Also create the first new ui library `ui-buttons` which will be the new standard for buttons ins SCM-Manager. In this library we reconsidered which types of buttons should be used to create a clean and consistent ui.

Co-authored-by: Eduard Heimbuch <eduard.heimbuch@cloudogu.com>
2022-08-02 08:39:37 +02:00
Florian Scholdei
09beb8cd3b Add api doc for cli and more (#2101) 2022-08-01 21:42:21 +02:00
Eduard Heimbuch
4e220b5254 Implement more plugin list commands (#2094)
Implement commands to list available plugins and installed plugins separately.

Co-authored-by: René Pfeuffer <rene.pfeuffer@cloudogu.com>
2022-07-28 14:30:55 +02:00
René Pfeuffer
67a9dce7e6 Add namespace cli commands (#2093)
Adds the CLI commands that are available to handle repository permissions on repositories for namespaces.

Co-authored-by: Eduard Heimbuch <eduard.heimbuch@cloudogu.com>
2022-07-26 09:58:00 +02:00
René Pfeuffer
3e9bab1fa8 Fix translation keys 2022-07-21 13:58:58 +02:00
René Pfeuffer
48ade848d8 Align translations 2022-07-21 10:02:30 +02:00
Eduard Heimbuch
049b5ba54c Add CLI commands for global permission management (#2091)
Add CLI commands for permission management for users and groups.

Co-authored-by: Konstantin Schaper <konstantin.schaper@cloudogu.com>
2022-07-21 09:56:47 +02:00
René Pfeuffer
3b4b1a1767 Add cli commands to modify repository permissions (#2090)
Co-authored-by: Konstantin Schaper <konstantin.schaper@cloudogu.com>
2022-07-20 09:17:14 +02:00
Eduard Heimbuch
fc28da90b3 Enable plugin management via CLI (#2087)
Co-authored-by: Konstantin Schaper <konstantin.schaper@cloudogu.com>
2022-07-19 09:02:00 +02:00
Eduard Heimbuch
67c083ee54 Reduce code smells (#2089)
Reduce code smells found by deepsource.io. We focused on the low-hanging fruits and not breaking any api.
2022-07-15 15:33:37 +02:00
René Pfeuffer
f61d0c113f Always encrypt password (#2085)
First, we make "encryptPassword" in the PasswordService
idempotent, so that the method will not change the password
when the method is called with an already encrypted string.
Then, in the user manager, we will always call this method
to encrypt the password, if this is not already the case.

Co-authored-by: Eduard Heimbuch <eduard.heimbuch@cloudogu.com>
2022-07-15 15:02:52 +02:00
René Pfeuffer
d7943a0551 Fix plugin wizard for foreign languages (#2086)
This fixes the plugin wizard, that throws a NullPointerException for other languages then Englisch or German.
2022-07-13 09:28:56 +02:00
Florian Scholdei
f3f19426c8 Unify password validation (#2077)
Passwords should be checked when created or changed in the frontend just as they are in the backend for REST and CLI.
Also extend the password validation to allow upto 1024 characters instead of 32.

Co-authored-by: Eduard Heimbuch <eduard.heimbuch@cloudogu.com>
2022-07-07 11:19:51 +02:00
Eduard Heimbuch
e3e6bbed7c Encrypt user password via CLI (#2080) 2022-07-06 14:03:56 +02:00
Florian Scholdei
5267a0556a Remove branch validation on overview (#2064)
Branches that have already been checked as valid should not be displayed as faulty on branch overview.

Co-authored-by: Eduard Heimbuch <eduard.heimbuch@cloudogu.com>
2022-06-09 07:30:46 +02:00
Eduard Heimbuch
084fe9e2ae Add api to overwrite content type resolver (#2051)
Introduce content type resolver extension to provide
custom content types for specific file extensions.
2022-06-07 11:02:56 +02:00
Konstantin Schaper
1b18191c57 Add plugin wizard initialization step (#2045)
Adds a new initialization step after setting up the initial administration account that allows administrators to initialize the instance with a selection of plugin sets.

Co-authored-by: René Pfeuffer <rene.pfeuffer@cloudogu.com>
Co-authored-by: Eduard Heimbuch <eduard.heimbuch@cloudogu.com>
Co-authored-by: Matthias Thieroff <matthias.thieroff@cloudogu.com>
2022-05-31 15:15:30 +02:00
Florian Scholdei
6216945f0d Notify user about results of manually executed health check (#2044)
When manually starting health checks, the user should always receive a notification about the status, whether successful or not.
2022-05-25 09:30:45 +02:00
Eduard Heimbuch
8f0facf394 Order repo info extensions (#2041)
Set order priority for repository information extensions.
Also add new annotation to set custom resource bundles for cli commands.
2022-05-23 15:06:08 +02:00
Eduard Heimbuch
b2751dc6a7 Add missing description key for repository get command 2022-05-20 11:09:00 +02:00
Matthias Thieroff
8981a98064 Fix language specific CLI problems (#2042)
Unit tests which deal with translated text need to be specific about
the language the test should use. Otherwise system default gets used
which may lead to problems. Also line endings may be a problem on
different OS.
This fixes two of the above issues.
2022-05-20 10:58:21 +02:00
René Pfeuffer
303f8daaf9 Fix NPE on synchronous repository export (#2040)
When a repository was exported synchronously with metadata,
the server ran into a NullPointerException. The was because
the resource tried to write an export result to a stored
export item, that does not exist for synchronous exports.

This simply removes this call.
2022-05-19 08:36:25 +02:00
Florian Scholdei
8448a3520b Correct resource for branch details (#2037)
The two BranchDetails resource endpoints were shown twice in the Rest Api documentation. Once each without path prefix.
This pr removes the duplicate endpoints.
2022-05-17 16:34:25 +02:00
Eduard Heimbuch
1c540e1fbd Sort CLI commands alphabetically (#2020)
Sort CLI commands alphabetically to show them in consistent order.
2022-05-04 09:36:01 +02:00
Eduard Heimbuch
77046bb6fd Throw error if repo is created with not supported type (#2019)
Throw error if repository is created with not supported type. Currently we only allow git, svn or hg all lowercase.
2022-05-03 16:06:38 +02:00
René Pfeuffer
c05ddf7376 Fix log in cli exception handler 2022-05-03 14:34:28 +02:00
René Pfeuffer
9e8ac9a05f Log exceptions in cli execution 2022-05-03 13:36:46 +02:00
René Pfeuffer
b8e2ae747a Omit default port in protocol urls (#2014)
This omits the port in the protocol urls when the port is the default port for the protocol.
So if you have your server https://my.scm.net/scm and the repository admin/test, the protocol url is no longer https://my.scm.net:443/scm/repo/admin/test, but simply https://my.scm.net/scm/repo/admin/test without the :443.
2022-04-29 11:57:28 +02:00
René Pfeuffer
84f7c5c099 Update jjwt to 0.11.5 (#2017)
Updates jjwt in response to CVE-2022-21449.

See https://github.com/jwtk/jjwt/blob/0.11.5/CHANGELOG.md?s=03#0115
2022-04-29 11:17:47 +02:00
Eduard Heimbuch
ca9b20940f Translate cli parameter exceptions (#1997)
Translate CLI parameter exceptions to german. We explictly do not translate the default english exceptions to custom ones since the default messages are more specific/helpful.
2022-04-13 08:47:32 +02:00
René Pfeuffer
d2e81ce121 Add cli commands for users and groups (#1993)
Adds cli commands to manage users and groups.

Co-authored-by: Matthias Thieroff <matthias.thieroff@cloudogu.com>
2022-04-11 10:04:19 +02:00
René Pfeuffer
e926711157 Use i18n for cli exception (#1989)
For scm exceptions, use the translations from plugins.json in the cli rest endpoint.
2022-04-06 14:30:30 +02:00
Eduard Heimbuch
02b3c5c810 Fix version command test 2022-04-06 13:07:41 +02:00
René Pfeuffer
dd3b616ba4 Limit scopes and rename bean (#1991)
This limits the scope of all cli related classes, so that
they cannot be used outside of cli context and therefore
cannot confuse other developers.

Secondly, we rename RepositoryCommandDto to
RepositoryCommandBean, because we have no data transfers
here and the name might be confusing otherwise.
2022-04-06 09:16:03 +02:00
Eduard Heimbuch
4823ed59a2 Add version command for cli client (#1988)
Implement version command to show client and server versions on command line client.
2022-04-05 08:20:18 +02:00
Eduard Heimbuch
162dd6ad0a CLI Support for repository actions (#1987)
To make SCM-Manager more accessible and to make it easier using scripts against the server, we created a command line interface. This command line interface can be used to perform the default actions like create, modify and delete repositories. It is also very flexible and can be extended by plugins.

The CLI already supports internationalization, help texts, input validation, loose and table-like templates and nested subcommands. Check the cli guidelines to learn how add new cli commands.

Co-authored-by: Sebastian Sdorra <sebastian.sdorra@cloudogu.com>
2022-04-04 12:02:16 +02:00