Commit Graph
78 Commits
Author SHA1 Message Date
Dmitriy Zaporozhets a74b66cdee Merge branch 'master' of dev.gitlab.org:gitlab/gitlabhq into upstream-ce
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>

Conflicts:
	app/models/group.rb
	app/models/project.rb
	features/steps/shared/project.rb
2014-07-10 23:43:42 +03:00
Jacob Vosmaer 41a3c84e40 Add logging code for LDAP keys 2014-07-09 12:18:20 +02:00
Jacob Vosmaer 526959ab63 Use a scope to add/remove LDAP keys
For some reason I needed to add a reload statement in the specs.
2014-07-09 12:13:09 +02:00
Jacob Vosmaer fe6202097a Create an Gitlab::LDAP::Person#ssh_keys attribute
This allows us to keep Person#entry private, and it makes
Access#update_ssh_keys a little shorter.
2014-07-09 11:06:53 +02:00
Marvin Frick 423960a435 adds spec for LDAPKeys (+4 squashed commits)
Squashed commits:
[812406c] fixes bug from last refactoring
[53e9508] hides "delete" button if a key is a LDAPKey
[bafc66b] refactores update_ssh_keys in own method
[7895858] makes name of ssh public key configurable
2014-07-08 12:41:12 +02:00
Oleg GirkoandMarvin Frick edaaac2f55 Make SSH keys synchronisation with LDAP not delete keys added by users.
This is done by using a separate LDAPKey model (inherited from Key)
for storing SSH keys which came from LDAP.
These keys can be viewed from user profile, but they can not be deleted.

Signed-off-by: Oleg Girko <oleg.girko@jollamobile.com> (+2 squashed commits)
Squashed commits:
[52b3816] Made SSH key synchronisation with LDAP configurable.

Now it can be turned on or off using configuration option
sync_ssh_keys in ldap section.
The default is off to preserve compatibility with old behaviour.

Signed-off-by: Oleg Girko <oleg.girko@jollamobile.com>
[02f988d] Synchronise LDAP users SSH keys from LDAP automatically.

SSH public keys are synchronised from sshPublicKey LDAP attribute
upon login attempt and during regular LDAP security checks.
New keys are added, old keys not present in LDAP are deleted.

Signed-off-by: Oleg Girko <oleg.girko@jollamobile.com> (+1 squashed commit)
Squashed commits:
[f087fbc] Make Gitlab::LDAP::Person.entry method public.

This is needed to allow access control methods to access
arbitrary LDAP attributes.

Signed-off-by: Oleg Girko <oleg.girko@jollamobile.com>
2014-07-08 12:31:11 +02:00
Marvin Frick 4be5c5a7a2 adds feature to sync GitLab admins with LDAP group 2014-06-23 18:17:14 +02:00
Boris HUISGEN bac7d17c7b Fix LDAP TLS authentication 2014-06-19 10:41:23 +02:00
Dmitriy Zaporozhets b165b097f5 Merge branch 'master' of dev.gitlab.org:gitlab/gitlabhq into ce-7-to-ee
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>

Conflicts:
	LICENSE
	VERSION
	app/controllers/omniauth_callbacks_controller.rb
	app/helpers/application_helper.rb
	app/helpers/merge_requests_helper.rb
	app/models/group.rb
	app/models/project.rb
	app/models/project_team.rb
	app/views/admin/groups/edit.html.haml
	app/views/groups/_projects.html.haml
	app/views/groups/edit.html.haml
	db/schema.rb
	doc/install/installation.md
	doc/integration/README.md
	lib/gitlab/git_access.rb
	lib/gitlab/markdown.rb
	spec/helpers/merge_requests_helper.rb
	spec/models/merge_request_spec.rb
2014-06-17 10:53:44 +03:00
Marin Jankovski 314e4736e4 Strip apostrophe from email generated usernames. 2014-06-11 17:06:28 +02:00
GitLab 19a8b6ce71 Remove copyright licenses missed in 0fdab6a747. 2014-06-02 09:11:24 +02:00
Marin Jankovski 7ab468317b Merge branch 'ldap_email_downcase' into 'master'
Fix LDAP email upper case bug
2014-05-22 06:59:13 +00:00
Jacob Vosmaer e52e5da88c Downcase the LDAP email address before comparing 2014-05-21 14:21:25 +02:00
Marin Jankovski 95ef8f9756 Merge remote-tracking branch 'ce/master'
Conflicts:
	VERSION
	doc/install/installation.md
	doc/integration/README.md
	doc/integration/external-issue-tracker.md
	lib/gitlab/markdown.rb
	spec/lib/gitlab/ldap/ldap_access_spec.rb
2014-05-21 13:10:37 +02:00
Jacob Vosmaer be1120e968 Improve ad_disabled method name 2014-05-14 19:13:06 +02:00
Jacob Vosmaer a966f72224 Document the Active Directory magic numbers 2014-05-14 19:08:42 +02:00
Jacob Vosmaer 11dba4cee7 Fix syntax error in AD disabled user filter 2014-05-14 18:54:05 +02:00
Jacob Vosmaer a6e4153878 Check for the AD disabled flag in Access#allowed? 2014-05-14 18:32:40 +02:00
Jacob Vosmaer a754f0b220 Add LDAP::Person#ad_disabled?
Check the bit for disabled Active Directory users. The filter is based
on http://ctogonewild.com/2009/09/03/bitmask-searches-in-ldap/ .
2014-05-14 18:26:58 +02:00
Jacob Vosmaer 982d4d51e8 Backport Adapter#dn_matches_filter? from EE 2014-05-14 18:11:14 +02:00
Jacob Vosmaer f4bca105d1 Backport Adapter#ldap_search from EE 2014-05-14 18:10:43 +02:00
Marin Jankovski d9c0ecdca8 Add scope to dn filter. 2014-05-09 14:51:29 +02:00
Marin Jankovski 47c0b4b172 Add scoping to ldap lookup. 2014-05-08 15:30:16 +02:00
Ben Bytheway de794b6a77 Add scoping to ldap lookup when only dn given 2014-04-23 21:00:56 -06:00
Dmitriy Zaporozhets eff30fff08 Improve dn_matches_filter method
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2014-04-15 17:27:59 +03:00
Dmitriy Zaporozhets 1fe677995c LDAP::Adapter#ldap_search method
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2014-04-15 16:50:31 +03:00
Dmitriy Zaporozhets fae2e540b6 Merge branch 'master' of dev.gitlab.org:gitlab/gitlabhq into upstream-ce-6-8
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>

Conflicts:
	CHANGELOG
	Gemfile.lock
	README.md
	VERSION
	app/assets/javascripts/application.js
	db/schema.rb
	doc/install/installation.md
	doc/update/4.2-to-5.0.md
	doc/update/5.0-to-5.1.md
	doc/update/5.1-to-5.2.md
	doc/update/5.2-to-5.3.md
	doc/update/5.4-to-6.0.md
	doc/update/6.0-to-6.1.md
	doc/update/6.0-to-6.7.md
	lib/gitlab/git_access.rb
2014-04-10 13:34:56 +03:00
Marin Jankovski 1187d3f28d Synchronize user email with ldap. 2014-04-04 13:08:28 +02:00
Dmitriy Zaporozhets fdeacf0ad1 Merge pull request #6317 from jirutka/fix-ldap-dn-case
Fix searching by extern_uid for LDAP to be case-insensitive
2014-03-29 14:08:31 +02:00
Jacob Vosmaer 2bfa02bb3c Check for errors in Adapter#dn_matches_filter? 2014-03-28 14:29:04 +01:00
Jacob Vosmaer 2e6b537018 Use omniauth nickname as the username for LDAP
Before there was a bug in omniauth-ldap which prevented samaccountname
showing up as a possible username for new LDAP users. Thanks to upstream
fixes, we no longer need to work around this bug.
2014-03-28 13:57:52 +01:00
Jacob Vosmaer 8722d6bdc4 Add an API reference for AD recursive LDAP lookup 2014-03-20 13:28:10 +01:00
Jacob Vosmaer ab37a0954a Add support for nested Active Directory groups 2014-03-20 09:41:15 +01:00
Jacob Vosmaer cc768fddeb Reuse LDAP adapter in Group instances 2014-03-20 09:39:25 +01:00
Jacob Vosmaer 823f89ed40 Pass LDAP adapter to finders in update_permissions 2014-03-14 11:21:50 +01:00
Jacob Vosmaer 2f1a59d391 Add Gitlab::LDAP::Access.open
This new method wraps Gitlab::LDAP::Adapter.open to enable connection
reuse.
2014-03-14 11:01:28 +01:00
Jacob Vosmaer d8ca6ed216 Add Gitlab::LDAP::Adapter.open
This new method is based on Net::LDAP.open, which reuses a single LDAP
connection.
2014-03-14 11:01:28 +01:00
Jacob Vosmaer f41d277d61 Allow passing an adapter to Gitlab::LDAP::Person 2014-03-14 11:01:27 +01:00
Jacob Vosmaer 56df3dbff2 Add Gitlab::LDAP::Access.open
This new method wraps Gitlab::LDAP::Adapter.open to enable connection
reuse.
2014-03-14 08:55:50 +01:00
Jacob Vosmaer af53aa9072 Add Gitlab::LDAP::Adapter.open
This new method is based on Net::LDAP.open, which reuses a single LDAP
connection.
2014-03-14 08:53:46 +01:00
Jacob Vosmaer 5a616649b5 Allow passing an adapter to Gitlab::LDAP::Person 2014-03-14 08:52:57 +01:00
Dmitriy Zaporozhets 0fdab6a747 Remove copyright
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2014-03-10 17:09:45 +02:00
Dmitriy Zaporozhets daa7f077db Port LDAP code from EE
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2014-03-10 14:48:08 +02:00
Jakub Jirutka 91e7692b66 Fix searching by extern_uid for LDAP to be case-insensitive 2014-02-18 19:38:22 +01:00
Jacob Vosmaer 0bfc45d518 Dump LDAP objects into the log for debugging 2014-02-12 15:51:30 +01:00
Dmitriy Zaporozhets 903726c846 Merge branch 'master' of dev.gitlab.org:gitlab/gitlabhq into upstream-ce
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>

Conflicts:
	CHANGELOG
	Gemfile
	VERSION
	app/models/group.rb
	app/views/groups/edit.html.haml
	db/schema.rb
	doc/install/installation.md
	doc/update/5.4-to-6.0.md
2014-02-11 10:15:13 +02:00
skv a3f645ef51 Remove deprecated finders 2014-01-19 23:39:56 +04:00
Dmitriy Zaporozhets 1f43fa20d3 Merge branch '6-4-stable' of dev.gitlab.org:gitlab/gitlabhq into 6-4-from-ce
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>

Conflicts:
	Gemfile
	Gemfile.lock
	VERSION
	app/controllers/application_controller.rb
	db/schema.rb
	doc/install/installation.md
	doc/update/6.2-to-6.3.md
2013-12-23 12:57:22 +02:00
Dmitriy Zaporozhets d3844662ec Respect existing group permissions during sync with LDAP group
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2013-12-14 13:22:51 +02:00
Sytse Sijbrandij 71e92681f2 We welcome everyone to contribute. 2013-12-01 11:53:00 +01:00