Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100755 84 lines (78 sloc) 3.545 kb
7183c5b from CVS
graziano obertelli authored
1 #!/usr/bin/perl
48052e3 added license header to source files (not clc/)
root authored
2 #
054a11a Garrett Holmstrom Update GPL+BSD file headers
gholms authored
3 # Copyright 2009-2012 Eucalyptus Systems, Inc.
48052e3 added license header to source files (not clc/)
root authored
4 #
054a11a Garrett Holmstrom Update GPL+BSD file headers
gholms authored
5 # This program is free software: you can redistribute it and/or modify
6 # it under the terms of the GNU General Public License as published by
7 # the Free Software Foundation; version 3 of the License.
48052e3 added license header to source files (not clc/)
root authored
8 #
054a11a Garrett Holmstrom Update GPL+BSD file headers
gholms authored
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY; without even the implied warranty of
11 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 # GNU General Public License for more details.
48052e3 added license header to source files (not clc/)
root authored
13 #
054a11a Garrett Holmstrom Update GPL+BSD file headers
gholms authored
14 # You should have received a copy of the GNU General Public License
15 # along with this program. If not, see http://www.gnu.org/licenses/.
48052e3 added license header to source files (not clc/)
root authored
16 #
054a11a Garrett Holmstrom Update GPL+BSD file headers
gholms authored
17 # Please contact Eucalyptus Systems, Inc., 6755 Hollister Ave., Goleta
18 # CA 93117, USA or visit http://www.eucalyptus.com/licenses/ if you need
19 # additional information or have any questions.
48052e3 added license header to source files (not clc/)
root authored
20 #
054a11a Garrett Holmstrom Update GPL+BSD file headers
gholms authored
21 # This file may incorporate work covered under the following copyright
22 # and permission notice:
48052e3 added license header to source files (not clc/)
root authored
23 #
054a11a Garrett Holmstrom Update GPL+BSD file headers
gholms authored
24 # Software License Agreement (BSD License)
48052e3 added license header to source files (not clc/)
root authored
25 #
054a11a Garrett Holmstrom Update GPL+BSD file headers
gholms authored
26 # Copyright (c) 2008, Regents of the University of California
27 # All rights reserved.
48052e3 added license header to source files (not clc/)
root authored
28 #
054a11a Garrett Holmstrom Update GPL+BSD file headers
gholms authored
29 # Redistribution and use of this software in source and binary forms,
30 # with or without modification, are permitted provided that the
31 # following conditions are met:
48052e3 added license header to source files (not clc/)
root authored
32 #
054a11a Garrett Holmstrom Update GPL+BSD file headers
gholms authored
33 # Redistributions of source code must retain the above copyright
34 # notice, this list of conditions and the following disclaimer.
35 #
36 # Redistributions in binary form must reproduce the above copyright
37 # notice, this list of conditions and the following disclaimer
38 # in the documentation and/or other materials provided with the
39 # distribution.
40 #
41 # THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
42 # "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
43 # LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
44 # FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
45 # COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
46 # INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
47 # BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
48 # LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
49 # CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
50 # LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
51 # ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
52 # POSSIBILITY OF SUCH DAMAGE. USERS OF THIS SOFTWARE ACKNOWLEDGE
53 # THE POSSIBLE PRESENCE OF OTHER OPEN SOURCE LICENSED MATERIAL,
54 # COPYRIGHTED MATERIAL OR PATENTED MATERIAL IN THIS SOFTWARE,
55 # AND IF ANY SUCH MATERIAL IS DISCOVERED THE PARTY DISCOVERING
56 # IT MAY INFORM DR. RICH WOLSKI AT THE UNIVERSITY OF CALIFORNIA,
57 # SANTA BARBARA WHO WILL THEN ASCERTAIN THE MOST APPROPRIATE REMEDY,
58 # WHICH IN THE REGENTS' DISCRETION MAY INCLUDE, WITHOUT LIMITATION,
59 # REPLACEMENT OF THE CODE SO IDENTIFIED, LICENSING OF THE CODE SO
60 # IDENTIFIED, OR WITHDRAWAL OF THE CODE CAPABILITY TO THE EXTENT
61 # NEEDED TO COMPLY WITH ANY SUCH LICENSES OR RIGHTS.
7183c5b from CVS
graziano obertelli authored
62
63 $policypath = shift @ARGV || die "USAGE: cat <service.xml> | add_server_policy.pl <policy_path>\n";
64
65 $found=0;
66 while(<STDIN>) {
67 my $orig = $_;
68 my $line = $orig;
69 chomp $line;
70 $added = "";
71 if ($found == 0) {
72 if ($line =~ /^\s*<\/service>/) {
73 $added = "<module ref=\"rampart\"/>\n";
74 $added .= `cat $policypath | sed "s:EUCALYPTUS_HOME:\$EUCALYPTUS:g" | sed "s:AXIS2C_HOME:\$AXIS2C_HOME:g"`;
75 }
76 }
77
78 print ("$added");
79 print ("$orig");
80
81
82 }
83 exit 0;
Something went wrong with that request. Please try again.