You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@vcl.apache.org by ar...@apache.org on 2009/05/18 19:21:32 UTC
svn commit: r776015 -
/incubator/vcl/trunk/managementnode/lib/VCL/Module/OS/Windows_mod.pm
Author: arkurth
Date: Mon May 18 17:21:32 2009
New Revision: 776015
URL: http://svn.apache.org/viewvc?rev=776015&view=rev
Log:
VCL-120
Added Windows_mod.pm::disable_ie_configuration_page(). This configures the registry to prevent the initial IE configuration page from appearing for users. Added a call to this sub in pre_capture().
Also removed call to allow_remote_access() in firewall_enable_rdp() and added a call to it in pre_capture(). This speeds up the tasks that occur after a user clicks the Connect button.
Modified:
incubator/vcl/trunk/managementnode/lib/VCL/Module/OS/Windows_mod.pm
Modified: incubator/vcl/trunk/managementnode/lib/VCL/Module/OS/Windows_mod.pm
URL: http://svn.apache.org/viewvc/incubator/vcl/trunk/managementnode/lib/VCL/Module/OS/Windows_mod.pm?rev=776015&r1=776014&r2=776015&view=diff
==============================================================================
--- incubator/vcl/trunk/managementnode/lib/VCL/Module/OS/Windows_mod.pm (original)
+++ incubator/vcl/trunk/managementnode/lib/VCL/Module/OS/Windows_mod.pm Mon May 18 17:21:32 2009
@@ -196,6 +196,17 @@
if (!$self->disable_dynamic_dns()) {
notify($ERRORS{'WARNING'}, 0, "unable to disable dynamic dns");
}
+
+
+=item *
+
+Disable Internet Explorer configuration page
+
+=cut
+
+ if (!$self->disable_ie_configuration_page()) {
+ notify($ERRORS{'WARNING'}, 0, "unable to disable IE configuration");
+ }
=item *
@@ -262,6 +273,16 @@
notify($ERRORS{'WARNING'}, 0, "unable to enable DHCP on the public and private interfaces");
return 0;
}
+
+=item *
+
+Allow users to connect remoteley
+
+=cut
+
+ if (!$self->allow_remote_access()) {
+ notify($ERRORS{'WARNING'}, 0, "unable to allow users to connect remotely");
+ }
=item *
@@ -3878,14 +3899,6 @@
notify($ERRORS{'CRITICAL'}, 0, "subroutine was called as a function, it must be called as a class method");
return;
}
-
- # Allow users to connect remotely
- if ($self->allow_remote_access()) {
- notify($ERRORS{'OK'}, 0, "allowed users to connect remotely");
- }
- else {
- notify($ERRORS{'WARNING'}, 0, "failed to allow users to connect remotely");
- }
my %firewall_parameters = (name => 'Remote Desktop',
protocol => 'TCP',
@@ -5956,6 +5969,55 @@
#/////////////////////////////////////////////////////////////////////////////
+=head2 disable_ie_configuration_page
+
+ Parameters : None.
+ Returns : If successful: true
+ If failed: false
+ Description : Sets registry keys which prevent Internet Explorer's
+ configuration page from appearing the first time a user launches
+ it. This subroutine also enables the Internet Explorer Phishing
+ Filter and sets it to not display a balloon message.
+
+=cut
+
+sub disable_ie_configuration_page {
+ my $self = shift;
+ unless (ref($self) && $self->isa('VCL::Module')) {
+ notify($ERRORS{'CRITICAL'}, 0, "subroutine can only be called as a VCL::Module module object method");
+ return;
+ }
+
+ my $management_node_keys = $self->data->get_management_node_keys();
+ my $computer_node_name = $self->data->get_computer_node_name();
+
+ my $registry_string .= <<"EOF";
+Windows Registry Editor Version 5.00
+
+[HKEY_LOCAL_MACHINE\\Software\\Microsoft\\Internet Explorer\\Main]
+"RunOnceHasShown"=dword:00000001
+"RunOnceComplete"=dword:00000001
+
+[HKEY_LOCAL_MACHINE\\Software\\Microsoft\\Internet Explorer\\PhishingFilter]
+"Enabled"=dword:00000002
+"ShownVerifyBalloon"=dword:00000001
+
+EOF
+
+ # Import the string into the registry
+ if ($self->import_registry_string($registry_string)) {
+ notify($ERRORS{'OK'}, 0, "set the registry keys to disable IE runonce");
+ }
+ else {
+ notify($ERRORS{'WARNING'}, 0, "failed to set the registry key to disable IE runonce");
+ return 0;
+ }
+
+ return 1;
+}
+
+#/////////////////////////////////////////////////////////////////////////////
+
1;
__END__