initial commit of file from CVS for e-smith-ibays on Wed 12 Jul 08:56:45 BST 2023
This commit is contained in:
18
root/etc/e-smith/db/accounts/migrate/20ibay-accounts
Normal file
18
root/etc/e-smith/db/accounts/migrate/20ibay-accounts
Normal file
@@ -0,0 +1,18 @@
|
||||
{
|
||||
foreach my $ibay ($DB->get_all_by_prop(type => 'ibay'))
|
||||
{
|
||||
# SME9 introduced SSLRequireSSL with enabled/disabled.
|
||||
# This replaces local customisation, so migrate 'on' to 'enabled'
|
||||
$ibay->set_prop ('SSLRequireSSL', 'enabled') if (($ibay->prop ('SSLRequireSSL') || '') eq 'on');
|
||||
|
||||
# SME10 merge SSL property (setting to redirect to https) with SSLRequireSSL (setting to force SSL in a directory)
|
||||
# while they have two different purpose, most admin will want to protect one directory with SSL and ease access to their
|
||||
# client to gently redirect them to https, hence the merge.
|
||||
my $SSL = $DB->get_prop_and_delete($ibay->key, 'SSL') || 'disabled';
|
||||
|
||||
# if SSL is enabled or SSLRequireSSL is enabled we want the new one enabled
|
||||
# default remains empty for disabled for the moment
|
||||
$ibay->set_prop('SSLRequireSSL','enabled') if ($SSL eq 'enabled');
|
||||
|
||||
}
|
||||
}
|
@@ -0,0 +1 @@
|
||||
12
|
Reference in New Issue
Block a user