$tmp =~ s/[\'\"]?,?\s*$//;
$tmp =~ s/[\'\"]?\);\s*$//;
$listing = $tmp;
+ } elsif ( $tmp =~ /^\s*[\'\"]writeable[\'\"]/i ) {
+ $tmp =~ s/^\s*[\'\"]writeable[\'\"]\s*=>\s*[\'\"]?//i;
+ $tmp =~ s/[\'\"]?,?\s*$//;
+ $tmp =~ s/[\'\"]?\);\s*$//;
+ $writeable = $tmp;
} elsif ( $tmp =~ /^\s*[\'\"]search_tree[\'\"]/i ) {
$tmp =~ s/^\s*[\'\"]search_tree[\'\"]\s*=>\s*[\'\"]?//i;
$tmp =~ s/[\'\"]?,?\s*$//;
$ldap_protocol[$sub] = $protocol;
$ldap_limit_scope[$sub] = $limit_scope;
$ldap_listing[$sub] = $listing;
+ $ldap_writeable[$sub] = $writeable;
$ldap_search_tree[$sub] = $search_tree;
$ldap_starttls[$sub] = $starttls;
} elsif ( $options[0] =~ /^(data_dir|attachment_dir|theme_css|org_logo|signout_page)$/ ) {
sub command8 {
print "Here you can set the name of the link on the right of the page.\n";
- print "The default is 'SquirrelMail/'\n";
+ print "The default is 'SquirrelMail'\n";
print "\n";
print "[$WHT$provider_name$NRM]: $WHT";
$new_provider_name = <STDIN>;
} else {
$new_provider_name =~ s/[\r\n]//g;
$new_provider_name =~ s/^\s+$//g;
+ $new_provider_name =~ s/\'/\\'/g;
}
return $new_provider_name;
}
if ( $ldap_listing[$count] ) {
print " listing: $ldap_listing[$count]\n";
}
+ if ( $ldap_writeable[$count] ) {
+ print " writeable: $ldap_writeable[$count]\n";
+ }
if ( $ldap_search_tree[$count] ) {
print " search_tree: $ldap_search_tree[$count]\n";
}
print "Number of displayed entries is limited by maxrows setting.\n";
print "\n";
print "Don't enable this option for public LDAP directories.\n";
- print "This feature is experimental.\n";
print "\n";
print "Allow listing of LDAP directory? (y/N):";
$name = <STDIN>;
print "\n";
+ print "You can control write access to LDAP address book here. This option can\n";
+ print "be useful if you run small LDAP server and want to provide writable\n";
+ print "shared address book stored in LDAP to users of webmail interface.\n";
+ print "\n";
+ print "Don't enable this option for public LDAP directories.\n";
+ print "\n";
+ print "Allow writing to LDAP directory? (y/N):";
+ $name = <STDIN>;
+ if ( $name =~ /^y\n/i ) {
+ $name = 'true';
+ } else {
+ $name = 'false';
+ }
+ $ldap_writeable[$sub] = $name;
+
+ print "\n";
+
print "You can specify an additional search filter.\n";
print "This could be something like \"(objectclass=posixAccount)\".\n";
print "No filtering is performed by default. Press ENTER for default.\n";
@new_ldap_protocol = ();
@new_ldap_limit_scope = ();
@new_ldap_listing = ();
+ @new_ldap_writeable = ();
@new_ldap_search_tree = ();
@new_ldap_starttls = ();
@new_ldap_protocol = ( @new_ldap_protocol, $ldap_protocol[$count] );
@new_ldap_limit_scope = ( @new_ldap_limit_scope, $ldap_limit_scope[$count] );
@new_ldap_listing = ( @new_ldap_listing, $ldap_listing[$count] );
+ @new_ldap_writeable = ( @new_ldap_writeable, $ldap_writeable[$count] );
@new_ldap_search_tree = ( @new_ldap_search_tree, $ldap_search_tree[$count] );
@new_ldap_starttls = ( @new_ldap_starttls, $ldap_starttls[$count] );
}
@ldap_protocol = @new_ldap_protocol;
@ldap_limit_scope = @new_ldap_limit_scope;
@ldap_listing = @new_ldap_listing;
+ @ldap_writeable = @new_ldap_writeable;
@ldap_search_tree = @new_ldap_search_tree;
@ldap_starttls = @new_ldap_starttls;
print "This option controls what character set is used when sending\n";
print "mail and when sending HTML to the browser. Option works only\n";
print "with US English (en_US) translation. Other translations use\n";
- print "charsets that are set in functions/i18n.php.\n";
+ print "charsets that are set in translation settings.\n";
print "\n";
print "[$WHT$default_charset$NRM]: $WHT";
# boolean
print CF " 'listing' => $ldap_listing[$count]";
}
+ if ( $ldap_writeable[$count] ) {
+ print CF ",\n";
+ # boolean
+ print CF " 'writeable' => $ldap_writeable[$count]";
+ }
if ( $ldap_search_tree[$count] ) {
print CF ",\n";
# integer