Commit Graph

160 Commits (b75450ad361bd7c468af5a01f42d203010206f62)

Author SHA1 Message Date
Bwko fa3abc22c0 Added sorting to organizations, repos & users page ()
Alexander Lunegov d5d21b67d2 Fix string format verbs ()
Denis Denisov 380e32e129 Fix random string generator ()
* Remove unused custom-alphabet feature of random string generator

Fix random string generator

Random string generator should return error if it fails to read random data via crypto/rand

* Fixes variable (un)initialization mixed assign
Update test GetRandomString
Lunny Xiao ec87a75c00 golint fixed for modules/auth
Lunny Xiao 94da472717 Golint fixed for modules/setting ()
* golint fixed for modules/setting

* typo fixed and renamed UNIXSOCKET to UnixSocket
Lunny Xiao 659bc2814c go lint fixed for routers/admin
Sandro Santilli 4247304f5a Update import paths from github.com/go-gitea to code.gitea.io ()
- Update import paths from github.com/go-gitea to code.gitea.io
- Fix import path for travis

See https://docs.travis-ci.com/user/languages/go#Go-Import-Path
Thibault Meyer 3a10a0c1ca
Ordering organizations and users by name
Sandro Santilli 864d1b1f9f Fix type in unused constant name ()
* Write LDAP, SMTP, PAM, DLDAP back to all uppercase

* Fix type in unused constant name

* Other MixCased fixes

* Complete MixerCasing of template constants

* Re uppercase LTS and LDAPS suffixes

* Uppercase JSON suffix in constant names

* Proper case LoginNoType

* Prefix unexported template path constants with "tpl"
Sandro Santilli aadd7dcdc3 And others
Sandro Santilli 05fd9d3f09 Security protocols
Sandro Santilli 7612b5ec40 More mixage
Sandro Santilli 60c82a8780 More...
Rémy Boulanouar 2d68bd1ef9 Change import reference to match gitea instead of gogs ()
Unknwon 152e715999 models/login_source: code improvement
Unknwon 99c2ae7b35 use alert instead 500 for duplicated login source name
Thibault Meyer 6a81632e36 Fix typo CacheInternal -> CacheInterval ()
Unknwon b85927e488 show Git configs on admin panel
Sandro Santilli 90dd0657b5 Add support for federated avatars ()
* Add support for federated avatars

Fixes 

Removes avatar fetching duplication code
Adds an "Enable Federated Avatar" checkbox in user settings
(defaults to unchecked)

Moves avatar settings all in the same form, making
local and remote avatars mutually exclusive

Renames UploadAvatarForm to AvatarForm
as it's not anymore only for uploading

* Run gofmt on all modified files

* Move Avatar form in its own page

* Add go-libravatar dependency to vendor/ dir

Hopefully helps with accepting the contribution.
See also 

* Revert "Add go-libravatar dependency to vendor/ dir"

This reverts commit a8cb93ae640bbb90f7d25012fc257bda9fae9b82.

* Make federated avatar setting a global configuration

Removes the per-user setting

* Move avatar handling back to base tool, disable federated avatar in offline mode

* Format, handle error

* Properly set fallback host

* Use unsupported github.com mirror for importing go-libravatar

* Remove comment showing life exists outside of github.com

... pity, but contribution would not be accepted otherwise

* Use Combo for Get and Post methods over /avatar

* FEDERATED_AVATAR -> ENABLE_FEDERATED_AVATAR

* Fix persistance of federated avatar lookup checkbox at install time

* Federated Avatars -> Enable Federated Avatars

* Use len(string) == 0 instead of string == ""

* Move import line where it belong

See
https://github.com/Unknwon/go-code-convention/blob/master/en-US/import_packages.md

Pity the import url is still the unofficial one, but oh well...

* Save a line (and waste much more expensive time)

* Remove redundant parens

* Remove an empty line

* Remove empty lines

* Reorder lines to make diff smaller

* Remove another newline

Unknwon review got me start a fight against newlines

* Move DISABLE_GRAVATAR and ENABLE_FEDERATED_AVATAR after OFFLINE_MODE

On re-reading the diff I figured what Unknwon meant here:
https://github.com/gogits/gogs/pull/3320/files#r73741106

* Remove newlines that weren't there before my intervention
Unknwon 1f2e173a74 Refactor User.Id to User.ID
Unknwon 46e96c008c Use struct for UI settings
Unknwon c083d76567 able to prohibit user login
Unknwon f1b8d52eb3 fix no mail notification when issue is closed/reopened
Unknwon 401bf944ef Use SecurityProtocol to replace UseSSL in LDAP config
Initially proposed by  and fixes  as well.
Unknwon 149d62a648 fix admin can't search private repos
- update glide info
Unknwon 2bf8494332 finish user and repository search
Both are possible on explore and admin panel
Unknwon 514382e2eb Rename module: middleware -> context
Unknwon 045f14fbd0 finsih UI work for access mode of collaborators
Collaborators have write access as default, and can be changed via repository
collaboration settings page to change between read, write and admin.
Unknwon f946040fa9 attempt to fix expected invalid CSRF token
- Remove unused config settings `[picture] service`
Unknwon 8055a0bdac Post work for
Improve test cases, config settings, also show SSH config settings on admin config panel.
Unknwon baaf6046a1 Minor fix for
Josh Frye c27038e392 Test mailer button. Addresses
Unknwon d8a994ef24 Move cron module to independent package
Make it easier to keep track of upstream changes and bug fixes
Adam Strzelecki 834d92a47b LDAP: Fetch attributes in Bind DN context option
This is feature is workaround for  (JumpCloud) and some other services
that allow LDAP search only under BindDN user account, but not allow any LDAP
search query in logged user DN context.

Such approach is an alternative to minimal permissions security pattern for
BindDN user.
Unknwon 04be8c0de5 reinitialize all repos from the db
- Update locales
Unknwon 3d5d61778a disable password change for non-local users
Unknwon 2a0bb1fa90 Limit repo creation
Unknwon 89244b74c6 remember page number when delete repo
Unknwon ca8ce793d1 Ability to delete repo from admin panel
Unknwon 978dc00305 APIs: admin users
Unknwon f41360d864 advanced select ops for system notices
Unknwon 0be8b1b1a1 Ability to batch delete system notices
Adam Strzelecki 573305f3d3 LDAP: Optional user name attribute specification
Consider following LDAP search query example:

    (&(objectClass=Person)(|(uid=%s)(mail=%s)))

Right now on first login attempt Gogs will use the text supplied on login form
as the newly created user name. In example query above the text matches against
both e-mail or user name. So if user puts the e-mail then the new Gogs user
name will be e-mail which may be undesired.

Using optional user name attribute setting we can explicitly say we want Gogs
user name to be certain LDAP attribute eg. `uid`, so even user will use e-mail
to login 1st time, the new account will receive correct user name.
Unknwon efea642d6c add admin op: delete missing repos
Unknwon 10427b2178 fix
Unknwon 6f0a41b8b2 Allow local import only for admin users
Unknwon 932dbccb67 fix import path, fix
Unknwon 21e13cb51e Triggere mailer for admin created accounts
Unknwon 986447335d minor fix
无闻 84c727ae66 Merge pull request from sapk/fix-admin-repo-new-ui
Fix admin repos new ui