Commit Graph

12 Commits (fb1ed5de9443ba0ea382dd80ed93d35efe9e164d)

Author SHA1 Message Date
Ethan Koenig 29f3a6e492 Fix rendering of external links ()
Lauris BH f189ccd2d6 Fix git hooks update to receive required arguments. Fixes ()
* Changed migration calling so that migrations can use models package
Kim "BKC" Carlbäcker d409d3ab57 Sanitation fix from Gogs ()
* Santiation fix from Gogs

* Linting

* Fix build-errors

* still not working

* Fix all the things!

* gofmt

* Add code-injection checks
Willem van Dreumel 01d957677f Oauth2 consumer ()
* initial stuff for oauth2 login, fails on:
* login button on the signIn page to start the OAuth2 flow and a callback for each provider
Only GitHub is implemented for now
* show login button only when the OAuth2 consumer is configured (and activated)
* create macaron group for oauth2 urls
* prevent net/http in modules (other then oauth2)
* use a new data sessions oauth2 folder for storing the oauth2 session data
* add missing 2FA when this is enabled on the user
* add password option for OAuth2 user , for use with git over http and login to the GUI
* add tip for registering a GitHub OAuth application
* at startup of Gitea register all configured providers and also on adding/deleting of new providers
* custom handling of errors in oauth2 request init + show better tip
* add ExternalLoginUser model and migration script to add it to database
* link a external account to an existing account (still need to handle wrong login and signup) and remove if user is removed
* remove the linked external account from the user his settings
* if user is unknown we allow him to register a new account or link it to some existing account
* sign up with button on signin page (als change OAuth2Provider structure so we can store basic stuff about providers)

* from gorilla/sessions docs:
"Important Note: If you aren't using gorilla/mux, you need to wrap your handlers with context.ClearHandler as or else you will leak memory!"
(we're using gorilla/sessions for storing oauth2 sessions)

* use updated goth lib that now supports getting the OAuth2 user if the AccessToken is still valid instead of re-authenticating (prevent flooding the OAuth2 provider)
Gabriel Jackson bf6f61cc69 Cleanup log messaging
This change corrects a few logging issues:

 * Standardized formatting errors with '%v'.
 * Standardized failure warning word usage.
 * Corrected an instance of using the standard log library when
   the gitea log library should be used instead.
Thomas Boerger 78535fb08e Allow custom public files ()
* Allow custom public files

* Gofmt code, lots of places not related to this pr
Lunny Xiao 2a80e5a81e bug fixed caused by ()
Ethan Koenig 833f8b94c2 Search bar for issues/pulls ()
Lunny Xiao 65b1875d2b New settings option for a custom SSH host () ()
* New settings option for a custom SSH host ()

* let default ssh listen addr empty
Thomas Boerger 83ed234472 Integrate templates into bindata optionally ()
Integrated optional bindata for the templates
Thomas Boerger 2932042a6d Get rid of bin folder within makefile, enabled TiDB ()
* Get rid of the bin folder within the build process

Signed-off-by: Thomas Boerger <thomas@webhippie.de>

* Dropped latest make task, it is unused

Signed-off-by: Thomas Boerger <thomas@webhippie.de>

* Added tidb tag to drone config

Signed-off-by: Thomas Boerger <thomas@webhippie.de>

* Dropped the cert build tag

Signed-off-by: Thomas Boerger <thomas@webhippie.de>

* Dropped useless minwinsvc build tag

Signed-off-by: Thomas Boerger <thomas@webhippie.de>

* Dropped the useless build tags from drone config

Signed-off-by: Thomas Boerger <thomas@webhippie.de>
Lunny Xiao 6ed7f269f1 Move init functions from routers/install to routers/init ()
* move init functions from routers/install to routers/init

* copyright typo