Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
bugzilla
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
etersoft
bugzilla
Commits
dbb4dc8e
Commit
dbb4dc8e
authored
Jul 11, 2006
by
lpsolit%gmail.com
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Bug 339731: [LDAP] URI-parsing code duplicated with Net::LDAP - Patch by…
Bug 339731: [LDAP] URI-parsing code duplicated with Net::LDAP - Patch by guillomovitch@zarb.org r=mkanat a=justdave
parent
c47738d0
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
16 additions
and
30 deletions
+16
-30
LDAP.pm
Bugzilla/Auth/Verify/LDAP.pm
+2
-28
installation.xml
docs/xml/installation.xml
+10
-1
ldap.html.tmpl
template/en/default/admin/params/ldap.html.tmpl
+4
-1
No files found.
Bugzilla/Auth/Verify/LDAP.pm
View file @
dbb4dc8e
...
@@ -40,9 +40,6 @@ use Bugzilla::Error;
...
@@ -40,9 +40,6 @@ use Bugzilla::Error;
use
Net::
LDAP
;
use
Net::
LDAP
;
use
constant
DEFAULT_PORT
=>
389
;
use
constant
DEFAULT_SSL_PORT
=>
636
;
use
constant
admin_can_create_account
=>
0
;
use
constant
admin_can_create_account
=>
0
;
use
constant
user_can_create_account
=>
0
;
use
constant
user_can_create_account
=>
0
;
...
@@ -140,31 +137,8 @@ sub ldap {
...
@@ -140,31 +137,8 @@ sub ldap {
my
$server
=
Bugzilla
->
params
->
{
"LDAPserver"
};
my
$server
=
Bugzilla
->
params
->
{
"LDAPserver"
};
ThrowCodeError
(
"ldap_server_not_defined"
)
unless
$server
;
ThrowCodeError
(
"ldap_server_not_defined"
)
unless
$server
;
my
$port
=
DEFAULT_PORT
;
$self
->
{
ldap
}
=
new
Net::
LDAP
(
$server
)
my
$protocol
=
"ldap"
;
||
ThrowCodeError
(
"ldap_connect_failed"
,
{
server
=>
$server
});
if
(
$server
=~
/(ldap|ldaps):\/\/(.*)/
)
{
# ldap(s)://server(:port)
$protocol
=
$1
;
my
$server_part
=
$2
;
if
(
$server_part
=~
/:/
)
{
# ldap(s)://server:port
(
$server
,
$port
)
=
split
(
":"
,
$server_part
);
}
else
{
# ldap(s)://server
$server
=
$server_part
;
if
(
$protocol
eq
"ldaps"
)
{
$port
=
DEFAULT_SSL_PORT
;
}
}
}
elsif
(
$server
=~
/:/
)
{
# server:port
(
$server
,
$port
)
=
split
(
":"
,
$server
);
}
my
$conn_string
=
"$protocol://$server:$port"
;
$self
->
{
ldap
}
=
new
Net::
LDAP
(
$conn_string
)
||
ThrowCodeError
(
"ldap_connect_failed"
,
{
server
=>
$conn_string
});
# try to start TLS if needed
# try to start TLS if needed
if
(
Bugzilla
->
params
->
{
"LDAPstarttls"
})
{
if
(
Bugzilla
->
params
->
{
"LDAPstarttls"
})
{
...
...
docs/xml/installation.xml
View file @
dbb4dc8e
<!-- <!DOCTYPE chapter PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN"> -->
<!-- <!DOCTYPE chapter PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN"> -->
<!-- $Id: installation.xml,v 1.12
1 2006/06/07 23:20:27 vladd%bugzilla.org
Exp $ -->
<!-- $Id: installation.xml,v 1.12
2 2006/07/11 00:42:58 lpsolit%gmail.com
Exp $ -->
<chapter
id=
"installing-bugzilla"
>
<chapter
id=
"installing-bugzilla"
>
<title>
Installing Bugzilla
</title>
<title>
Installing Bugzilla
</title>
...
@@ -1379,6 +1379,15 @@ c:\perl\bin\perl.exe -xc:\bugzilla -wT "%s" %s
...
@@ -1379,6 +1379,15 @@ c:\perl\bin\perl.exe -xc:\bugzilla -wT "%s" %s
<para>
Ex.
<quote>
ldap.company.com
</quote>
<para>
Ex.
<quote>
ldap.company.com
</quote>
or
<quote>
ldap.company.com:3268
</quote>
or
<quote>
ldap.company.com:3268
</quote>
</para>
</para>
<para>
You can also specify a LDAP URI, so as to use other
protocols, such as LDAPS or LDAPI. If port was not specified in
the URI, the default is either 389 or 636 for 'LDAP' and 'LDAPS'
schemes respectively.
</para>
<para>
Ex.
<quote>
ldap://ldap.company.com
</quote>
,
<quote>
ldaps://ldap.company.com
</quote>
or
<quote>
ldapi://%2fvar%2flib%2fldap_sock
</quote>
</para>
</listitem>
</listitem>
</varlistentry>
</varlistentry>
...
...
template/en/default/admin/params/ldap.html.tmpl
View file @
dbb4dc8e
...
@@ -27,7 +27,10 @@
...
@@ -27,7 +27,10 @@
[% param_descs = {
[% param_descs = {
LDAPserver => "The name (and optionally port) of your LDAP server " _
LDAPserver => "The name (and optionally port) of your LDAP server " _
"(e.g. ldap.company.com, or ldap.company.com:portnum). " _
"(e.g. ldap.company.com, or ldap.company.com:portnum). " _
"Can be prefixed with ldap:// (default) or ldaps:// (for a secure connection).",
"URI syntax can also be used, such as "_
"ldaps://ldap.company.com (for a secure connection) or " _
"ldapi://%2fvar%2flib%2fldap_sock (for a socket-based " _
"local connection.",
LDAPstartls => "Whether to require encrypted communication once normal " _
LDAPstartls => "Whether to require encrypted communication once normal " _
"LDAP connection achieved with the server.",
"LDAP connection achieved with the server.",
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment