Milka Kuzminski
219a05baa4
permissions: use constant for fork enable/disable
2021-03-24 16:52:47 +01:00
Marcin Kuzminski
4e4f6160b6
permissions: fixed a case when a duplicate permission was making archive operation still display settings.
2020-06-25 09:41:32 +02:00
Marcin Kuzminski
159aca46c7
request-wrapper: expose usernames for better auditing capabilities.
2020-05-18 14:40:26 +02:00
Marcin Kuzminski
42302f7434
auth-user: enabled cache flags for fetching ACL ids.
...
- those are now safe to cache since we have a proper cache invalidation logic for permissions of users
- for lots of repo this makes our goto switcher much much faster
2020-05-05 13:18:55 +02:00
Marcin Kuzminski
fe96e16646
code: update copyrights to 2020
2020-04-16 00:34:52 +02:00
Marcin Lulek
780ec5f73e
core: added user-notice logic to push notice messages.
...
- will be used for exception tracker info
- new version upgrades
- dedicated important messages to the users
2020-04-09 12:30:13 +02:00
Marcin Kuzminski
540f9ad582
core: fixed cython compat inspect that caused some API calls to not work correctly.
2020-01-10 08:54:49 +01:00
Marcin Kuzminski
97cbe3b81b
caches: introduce cache_ver for permissions in order to be able to invalidate caches if cached code changes
2019-12-22 14:18:01 +01:00
Marcin Kuzminski
d62df5e549
auth-user: use new permissions helpers instead of defining the read list over and over.
2019-12-22 11:50:36 +01:00
Marcin Kuzminski
116ffd25d2
my-account: owner/watched repos are now loaded only using DB queries.
...
- major speed-up for large number of entries
- permissions checks using IN generator
2019-12-19 17:49:40 +01:00
Marcin Kuzminski
90db409b65
admin: made all grids use same partial loading logic
...
- dont load all results for repositories in admin
- speed up loading admin repos page by narrowing results based on permissions
- some small speed ups and code optimizations on permission loading
2019-12-19 11:42:25 +01:00
Daniel Dourvaris
4057ada739
webhelpers: port most of the items from webhelpers to webhelpers2
...
- webhelpers are deprecated and py2 only
2019-11-21 15:48:12 +01:00
Marcin Kuzminski
c6f649e139
artifacts: expose a special auth-token based artifacts download urls.
...
This will allow sharing download to external locations used new generated artifact download
tokens. This feature allows also serving downloads using secret urls with all the fancy logic
of our auth tokens.
2019-10-22 20:00:39 +02:00
Marcin Kuzminski
a7aeae1394
permissions: rename repository permissions to mention those are access permissions.
...
- Soon we'll introduce fine grained permissions for web-edit and artifacts that would require clear separation.
2019-10-09 15:01:03 +02:00
Marcin Kuzminski
928652312a
core: added more accurate time measurement for called functions
2019-07-17 16:28:41 +02:00
Marcin Kuzminski
0a8e792efc
auth: reduced usage of raw auth calls inside templates
2019-03-27 12:29:31 +01:00
Marcin Kuzminski
bd1a9c8201
docs: updated copyrights to 2019
2019-01-02 18:13:27 +01:00
Daniel Dourvaris
d299f7f7b4
branch permissions: fixed a case of showing branch permissions entries when inheritation model is used.
...
- the algo picker used not-explicit pattern but whole set
- fixes #5502
2018-10-25 11:28:00 +02:00
Marcin Kuzminski
2910f510dc
repositories: added option to archive repositories instead of deleting them.
...
- closes #5493
2018-09-25 17:28:11 +02:00
Marcin Kuzminski
9033601562
logging: use lazy parameter evaluation in log calls.
2018-09-13 17:41:35 +02:00
Marcin Kuzminski
08d3f6b83b
branch-permissions: enabled branch permissions checks for SSH backend.
2018-08-29 16:41:52 +02:00
Marcin Kuzminski
d3afc86451
branch-permissions: handle vcs operations and branch permissions.
...
- use new exceptions for branch permissions
- detect if we need to check permissions
- calculate super-admin the same way as regular users for override capabilities
- added new tests for branch permissions
2018-08-29 20:22:43 +02:00
Marcin Kuzminski
e41725c078
branch permissions: added logic to define in UI branch permissions.
...
- db models
- new permissions pages placeholders
2018-08-28 13:41:30 +02:00
Marcin Kuzminski
d6757c3989
core: removed last activity as it was creating lots of DB locks.
2018-07-26 21:54:44 +02:00
Marcin Kuzminski
9665179aa5
caches: use new decorator that uses conditional caches skipping dogpile if cache is disabled.
2018-07-14 18:17:42 +02:00
Marcin Kuzminski
ddc445856e
caches: rewrite of auth/permission caches to dogpile.
2018-07-05 20:14:33 +02:00
Marcin Kuzminski
564c09e772
ip-restritions: fix issue with loading empty IP rules for non-logged not-anonymous users.
...
This case won't have any IP rules set. And we accidentally loaded them becuase of no empty user filter
was present. This caused some odd display warnings for users.
2018-07-04 12:19:08 +02:00
Marcin Kuzminski
f62a1b94f7
tests: don't use md5 for testing crypto for compliance reasons.
2018-07-03 14:30:57 +02:00
Marcin Kuzminski
06ef71e55a
auth: code style, more python3 compat changes.
2018-06-27 17:05:24 +02:00
Marcin Kuzminski
e9d1e470b6
auth: code cleanup, use set literals for py3 compat
2018-06-27 17:26:15 +02:00
Marcin Kuzminski
eb7e9c6ce1
logging: updated logging information on IP checks.
2018-06-27 16:54:58 +02:00
Marcin Kuzminski
e32681449c
caches: switch other permission cache to use same cache region.
2018-06-22 18:35:41 +02:00
Marcin Kuzminski
2044170b28
caches: use different namespaces for conditional_cache wrapper.
...
Before we used one namespace for ALL meaning caches were kept in single file, or single DB row.
While this makes sense for single functions, a per-user, per-group cache should be divided to single files.
2018-06-22 17:31:48 +02:00
Marcin Kuzminski
9c384313d1
auth: update logging for permission calculation function
2018-06-22 13:34:58 +02:00
Marcin Kuzminski
e0b621ed56
permissions: enable caching by controlling short_term cache settings.
2018-06-15 19:36:19 +02:00
Marcin Kuzminski
00b45c1fa7
release: update copyright year to 2018
2018-01-19 17:13:16 +01:00
Marcin Kuzminski
f9f80e3ff9
feed-token, user, performance: lazy load the feed_token. We only need it for
...
scope of web requests. For vcs operations, we don't need it.
- 20ms to load this can save up much time for SVN requests.
2017-12-04 12:14:01 +01:00
Marcin Kuzminski
5f9ae2ae11
pylons: remove pylons as dependency
...
- dependencies: bumped:
-setuptools-scm==1.15.6
-celery==4.1.0
-kombu==4.1.0
-pytz==2017.3
-Routes==2.4.1
Removed all pylons components. Refactored the code to use only pyramid
parts
2017-11-15 13:42:54 +01:00
Marcin Kuzminski
f87eee826e
auth: remove pylons i18n and replaced it with pyramid translation
2017-11-13 00:09:01 +01:00
Marcin Kuzminski
10cad89493
auth: don't break hashing in case of user with empty password.
...
In some cases such as LDAP user created via external scripts users might
set the passwords to empty. The hashing uses the md5(password_hash) to
store reference to detect password changes and forbid using the same password.
In case of pure LDAP users this is not valid, and we shouldn't raise Errors in such
case. This change makes it work for empty passwords now.
2017-10-27 16:29:46 +02:00
Marcin Lulek
df9121dcf1
auth: don't expose full set of permissions into channelstream payload.
...
This leads to resource discovery security vulnerability
2017-10-08 23:31:45 +02:00
Marcin Kuzminski
b505377197
users: ported controllers from pylons into pyramid views.
2017-09-20 22:29:34 +02:00
Marcin Kuzminski
b8a108e1d4
sessions: don't use pylons sessions for csrf tokens
2017-09-19 23:29:03 +02:00
Marcin Kuzminski
4e50794cfb
auth: use consistent way of extracting came_from, and also sanitise it to remove
...
auth_token. This prevents a loop of redirection in case we get redirected to login
with this parameter.
2017-09-06 23:39:45 +02:00
Marcin Kuzminski
a8abeb0d1c
user-groups: rewrote the app to pyramid
...
- added new event data with added/removed/changed permissions
- cleanup code and spelling
2017-08-31 12:47:19 +02:00
Marcin Kuzminski
48959fcd73
auth: don't double register the permission in case no inheritance is turned on
2017-08-28 12:56:04 +02:00
Marcin Kuzminski
c0899ff09d
auth: expose a option to calculate how we end up having super-admin permission.
...
This is now used only for visual display. The old way is still faster for permissions
calculation.
- the extended way will be used in permission summary showing a much more detailed
permission summary for super-admins.
2017-08-27 19:30:42 +02:00
Marcin Kuzminski
54ad0eaea2
auth: use pesistent naming of keys in auth. Refactoring only.
2017-08-27 19:29:10 +02:00
Marcin Kuzminski
868ab0ed73
permissions: explicitly register all permissions set for user. Fixes #4217
...
- in order to get a proper inheritance chain of permissions we'll register each step.
This allows to get full inheritance chain. Final permissions will be the same becuase
the only thing we change is we register each step before permissions final value.
- Also display the permissions summary in a nicer way more explicitly stating what
permissions overwrites which.
2017-08-25 17:43:28 +02:00
Marcin Kuzminski
dcedd44327
auth: added additional name filters to the acl helpers.
...
- helps narrowing the results based on if we use a search param or not.
2017-08-16 21:51:10 +02:00