Mantis集成 LDAP 认证
mantis的用户认证函数Authentication中相关有
| $g_login_method |
|
| $g_ldap_server | The ldap server (eg: ldaps://ldap.example.com |
| $g_ldap_port | LDAP port (default 636). |
| $g_ldap_root_dn | “dc=example, dc=com” |
| $g_ldap_organisation | “organizationname=*Example)” |
| $g_use_ldap_email | Use email address in LDAP rather than the email stored in the database. |
| $g_ldap_bind_dn | “cn=Manager, dc=example, dc=com” |
| $g_ldap_bind_passwd |
由于需要涉及到几个程序的统一认证,所以需要mantis到windows的AD进行认证,竟然发现互联网上又没有相关文档,高手们太坏了。诶诶,害的我再次自力更生艰苦奋斗。
相关配置方法:
首先介绍微软的一款Support Tools,ldp.exe,用来查看AD的详细信息。
给出一个界面
在mantis的config_inc.php中配置以下信息,
$g_login_method=LDAP; //设置认证方法为LDAP
$g_ldap_server=’ldap://boofee.local’; //LDAP的访问路径
$g_ldap_port = ’389′; //端口,微软的AD是389
$g_ldap_organization = ”;
$g_ldap_uid_field = ‘CN’; //这句最重要,其他文档配置未成功就是这里出了错
$g_ldap_root_dn = ‘CN=Users,DC=boofee,DC=local’; //在AD中建立的相关用户在哪个组里面就将此配置到哪里,具体怎么写就是靠ldp.exe进行查询。
$g_ldap_bind_dn=”CN=user,CN=Users,DC=boofee,DC=local”; //连接AD的用户名,user权限就可以了。
$g_ldap_bind_passwd=”user”; //连接AD的密码
配置完成后基于AD的LDAP认证成功。
成功之后还是需要在mantis中建立用户名,在AD的相关组中也要有同样的用户名,认证的时候密码使用的是AD内存贮的密码。
转载自:http://www.boofee.net/flyingbamboo/archives/242
Mantis tweaks: logging in via Microsoft Active Directory LDAP
| This is a short article on how to get the above Mantis version to work with Microsoft Windows Active Directory LDAP. Used Mantis version: 1.1.1 and PHP Version 5 Mantis currently supports only login via LDAP directory by the following scheme: Connect to LDAP server Connect to LDAP server Step 1 Step 2 /* we want to use LDAP auth */ $g_login_method = LDAP; /* the root DN that will be used to form the bind DN during authentication phase */ /* we don't want the users to be able to sign-up via mantis */ /* we want to use Mantis email field instead of LDAP one */ /* we don't want false mantis lost password feature */ function ldap_authenticate( $p_user_id, $p_password ){ return $t_authenticated; CN=Firstname Lastname (username),ou=staff,ou=company,dc=domain,dc=com i.e. CN=John Doe (xy2093),ou=staff,ou=company,dc=domain,dc=com. You won’t believe it but that’s it! Now you can try to log in to Mantis with your LDAP password and it should work like a charm. The next issue to solve here is that you have to have the users from LDAP in your $mantis_user_table, for instance to manage Mantis privileges. There are many ways to achieve that, you can import them every night. Or you can use Mantis SOAP API to check if the user exists in LDAP when they try to log in as I did. But how to do that is another article ;) 转载自:http://www.warden.pl/2008/07/08/mantis-tweaks-getting-it-to-work-with-microsoft-ad-ldap/ |
Active directory settings
| Active directory settings
Introduction The page aims at describing how to configure mantis to connect to Active Directory. General principles Active Directory can currently be used by mantis for the following usage: Check user password. The way it proceeds is the following: Connect to Active Directory using LDAP protocol to search user by its login - A generic account is used for that purpose. The following parameters must be set in the config_inc.php file: $g_login_method = LDAP; $g_use_ldap_email = ON; You must add the following parameters in the config_inc.php file: $g_ldap_protocol_version = 3; http://www.mantisbt.org/wiki/doku.php/mantisbt:active_directory |
Mantis集成 LDAP 认证的更多相关文章
- LDAP落地实战(四):Jenkins集成OpenLDAP认证
前几篇分文章分别介绍了OpenLDAP的部署管理和维护以及svn.git的接入,今天我们再下一城接入jenkins. 前情提要:LDAP系列文章 LDAP落地实战(一):OpenLDAP部署及管理维护 ...
- LDAP落地实战(三):GitLab集成OpenLDAP认证
上一篇文章介绍了svn集成OpenLDAP认证,版本控制除了svn外,git目前也被越来越多的开发者所喜爱,本文将介绍GitLab如何集成openldap实现账号认证 GitLab集成OpenLDAP ...
- Django集成OpenLDAP认证
本文详细介绍了django-auth-ldap的使用方法,参数含义,并提供了示例代码 版本说明 Django==2.2 django-auth-ldap==1.7.0 集成过程 Django集成LDA ...
- 本地docker搭建gitlab, 并配置ldap认证
基于Docker在Mac OS X系统中的部署和设置GitLab的具体过程如下: 1. 安装Docker for Mac (参见https://docs.docker.com/docker-for ...
- LDAP落地实战(二):SVN集成OpenLDAP认证
上一篇文章我们介绍了LDAP的部署以及管理维护,那么如何接入LDAP实现账号统一认证呢?这篇文章将带你完成svn的接入验证 subversion集成OpenLDAP认证 系统环境:debian8.4 ...
- No.2 CAS之SPNEGO+LDAP认证配置
1.概述 本文先配置了SPNEGO认证,就是如果用户操作系统如果登陆了公司的Windows域,用户浏览器访问应用服务即可免登录. 然后如果不在域里的员工,用LDAP认证方式,输账号密码登陆. 参考文档 ...
- ldap配置系列二:jenkins集成ldap
ldap配置系列二:jenkins集成ldap jenkins简介 jenkins是一个独立的.开放源码的自动化服务器,它可以用于自动化与构建.测试.交付或部署软件相关的各种任务. jenkins官方 ...
- Jenkins-配置LDAP认证
Jenkins-配置LDAP认证 参考文档: LDAP添加用户详见我的博文 Linux分类 中的< LDAP2-创建OU和用户>博文. 1.LDAP配置 1.准备一个adminDN账号用 ...
- hive、impala集成ldap
1.概要 1.1 环境信息 hadoop:cdh5.10 os:centos6.7 user:root hive.impala已集成sentry 1.2 访问控制权限 这里通过使用openldap来控 ...
随机推荐
- XeLaTeX下如何以原大小显示PNG
在XeLaTeX里直接使用\includegraphics{test.png}这样的命令引入PNG,可能会发现图片直接被缩放到占满文档宽度,这是因为PNG这种bitmap类型的图片里通常不会带上met ...
- GUC-10 线程八锁
/* * 题目:判断打印的 "one" or "two" ? * * 1. 两个普通同步方法,两个线程,标准打印, 打印? //one two * 2. 新增 ...
- CRLF LF CR
The Carriage Return (CR) character (0x0D, \r) moves the cursor to the beginning of the line without ...
- pymongo处理正则表达式的情况
在python里使用pymongo处理mongodb数据库,在插入或者查询的时候,我们有时需要使用操作符号,如set,in, 具体操作符的可以参考 https://docs.mongodb.com/ ...
- java程序员修炼之道——大牛告诉我们应该好好学习与修炼以下知识与技能
—————————— ASP.Net+Android+IOS开发..Net培训.期待与您交流! —————————— 一:Java语言学习(对线程(thread),串行化,反射,网络编程,JNI技术, ...
- 自然语言处理系列-1.什么是NLP?
常常会听到有人说,自然语言处理(NLP)是人工智能技术(AI)皇冠上的明珠.那么,从这句话上就能够看到,目前我们常常说的NLP其实是AI技术的一个分支,而且是较难的那一个分支. 那么,到底什么是NLP ...
- PHP接入微信H5支付
开发前配置 进行代码接入前,需在微信后台填写授权回调域名,此域名必须经过ICP备案 开发主要流程 用户下单时选择微信支付 商户进行业务逻辑处理并调用微信统一下单接口,微信H5交易类型为:trade_t ...
- IDEA导入eclipse项目并部署运行完整步骤(转发)
首先说明一下:idea里的project相当于eclipse里的workspace,而idea里的modules相当于eclipse里的project 1.File-->Import Proje ...
- JavaSE基础之JDBC
JavaSE基础之JDBC 1.JDBC 的步骤: ①加载数据库驱动: a.MySQL:com.mysql.jdbc.Driver: b.SQLServer:com.microsoft.jdbc.sq ...
- luogu4770 [NOI2018]你的名字 后缀自动机 + 线段树合并
其实很水的一道题吧.... 题意是:每次给定一个串\(T\)以及\(l, r\),询问有多少个字符串\(s\)满足,\(s\)是\(T\)的子串,但不是\(S[l .. r]\)的子串 统计\(T\) ...