debian/0000755000000000000000000000000012160632144007165 5ustar debian/launcher-header0000644000000000000000000000105512160631467012147 0ustar #!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the # License is located at http://aws.amazon.com/asl or in the "license" file accompanying this file. This file is distributed on an "AS # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. debian/source/0000755000000000000000000000000012160632144010465 5ustar debian/source/format0000644000000000000000000000001412160631467011702 0ustar 3.0 (quilt) debian/shared-java-libs0000644000000000000000000000221512160632074012226 0ustar # each line is 3 fields: # - a file path under lib/ # - the name of a packaged java library that can replace that # - the name of the jar in the packaged library apache-log4j-1.2.15/log4j-1.2.15.jar liblog4j1.2-java log4j-1.2.jar #args4j-2.0.10/args4j-2.0.10.jar #aws-iam-cli/AWSIdentityManagementServiceCLI.jar commons-codec-1.3/commons-codec-1.3.jar libcommons-codec-java commons-codec.jar commons-httpclient-4.1.1/httpclient-4.1.1.jar libhttpclient-java httpclient.jar commons-httpclient-4.1.1/httpcore-4.1.jar libhttpcore-java httpcore.jar commons-logging-1.1.1/commons-logging-1.1.1.jar libcommons-logging-java commons-logging.jar #commons-logging-1.1.1/commons-logging-1.1.1-javadoc.jar #commons-logging-1.1.1/commons-logging-1.1.1-sources.jar commons-logging-1.1.1/commons-logging-adapters-1.1.1.jar libcommons-logging-java commons-logging-adapters.jar commons-logging-1.1.1/commons-logging-api-1.1.1.jar libcommons-logging-java commons-logging-api.jar #commons-logging-1.1.1/commons-logging-tests.jar saxonhe-9.0.2j/saxon9he.jar debian/changelog0000644000000000000000000000355712160632137011053 0ustar iamcli (1.5.0-0ubuntu3) saucy; urgency=low * depend on libhttpcore-java to provide version consistent with libhttpclient-java. (LP: #1193041) -- Scott Moser Thu, 20 Jun 2013 12:57:01 -0400 iamcli (1.5.0-0ubuntu2) quantal; urgency=low * revert the removal of 'IsTruncated: false'. It is intended output. future upstreams may address this. -- Scott Moser Fri, 15 Jun 2012 22:06:39 -0400 iamcli (1.5.0-0ubuntu1) quantal; urgency=low * New upstream release. Upstream released 2012-06-11. adds new commands: 1.3.0 (2011-11-02) iam-virtualmfadevicecreate iam-virtualmfadevicedel iam-virtualmfadevicelist 1.4.0 (2012-03-02) iam-accountdelpasswordpolicy iam-accountgetpasswordpolicy iam-accountmodpasswordpolicy iam-userchangepassword 1.5.0 (2012-06-11) iam-instanceprofileaddrole, iam-instanceprofilecreate iam-instanceprofiledel, iam-instanceprofilegetattributes iam-instanceprofilelistbypath, iam-instanceprofilelistforrole iam-instanceprofileremoverole, iam-roleaddpolicy, iam-rolecreate iam-roledel, iam-roledelpolicy, iam-rolegetattributes iam-rolelistbypath, iam-rolelistpolicies, iam-roleupdateassumepolicy, iam-roleuploadpolicy * remove 'IsTruncated: false' output (LP: #897519) * add dependency on libhttpclient-java -- Scott Moser Fri, 15 Jun 2012 16:15:06 -0400 iamcli (1.2.0-0ubuntu1) oneiric; urgency=low * New upstream release (LP: #797395) adds new commands: iam-accountaliascreate iam-accountaliasdelete iam-accountaliaslist iam-accountgetsummary -- Scott Moser Tue, 05 Apr 2011 14:41:56 -0400 iamcli (1.1.0-0ubuntu1) natty; urgency=low * Initial release (LP: #675686) -- Scott Moser Sun, 07 Nov 2010 22:47:45 -0500 debian/copyright0000644000000000000000000001130012160631467011122 0ustar Format-Specification: http://svn.debian.org/wsvn/dep/web/deps/dep5.mdwn?op=file&rev=135 Name: iamcli Maintainer: Scott Moser Source: http://developer.amazonwebservices.com/connect/entry.jspa?externalID=4143&categoryID=322 Copyright: 2006-2010, Amazon.com, Inc. or its affiliates License: Amazon Software License Copyright 2006-2010 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the License is located at http://aws.amazon.com/asl or in the "license" file accompanying this file. This file is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. Files: lib/apache-log4j-1.2.15/ lib/commons-codec-1.3 lib/commons-httpclient-4.1.1 lib/commons-logging-1.1.1 Copyright: Copyright 2007, The Apache Software Foundation License: Apache-2.0 The complete text of the Apache License version 2.0 can be seen in /usr/share/common-licenses/Apache-2.0 . Files: lib/args4j-2.0.10/ Copyright: 2003, Kohsuke Kawaguchi License: Other All rights reserved. . Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: . * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. . THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. Copyright: Michael Kay Files: lib/saxonhe-9.0.2j License: Mozilla Public License version 1.0 The contents of these file are subject to the Mozilla Public License Version 1.0 (the "License"); you may not use these files except in compliance with the License. You may obtain a copy of the License at http://www.mozilla.org/MPL/ Software distributed under the License is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limitations under the License. The Original Code is all Saxon modules labelled with a notice referring to this license. Portions created by other named contributors are copyright as identified in the relevant module. All Rights Reserved. Contributor(s) are listed in the documentation: see notices/contributors. Copyright: 2010, Canonical Ltd. Files: debian/* License: GPL-3 This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License version 3, as published by the Free Software Foundation. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . The complete text of the GPL version 3 can be seen in /usr/share/common-licenses/GPL-3. Copyright: 2006-2010, Amazon.com, Inc. or its affiliates Files: debian/launcher-* License: Amazon Software License Copyright 2006-2010 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the License is located at http://aws.amazon.com/asl or in the "license" file accompanying this file. This file is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. debian/rules0000755000000000000000000000137412160631467010261 0ustar #!/usr/bin/make -f DEB_DEBIAN_DIR=$(dir $(firstword $(MAKEFILE_LIST))) DEB_UPSTREAM_VERSION=$(shell dpkg-parsechangelog -l$(DEB_DEBIAN_DIR)/changelog \ | sed -rne 's,^Version: ([^-]+).*,\1,p') UPSTREAM_URL := http://awsiammedia.s3.amazonaws.com/public/tools/cli/latest/IAMCli.zip %: dh $@ # upstream does not provide anything but the current version .zip files as download get-orig-source: $(DEB_DEBIAN_DIR)/repack-zip $(UPSTREAM_URL) @[ -f "IAMCli-$(DEB_UPSTREAM_VERSION).tar.gz" ] || \ { echo "FAIL: upstream version != $(DEB_UPSTREAM_VERSION)" 1>&2; exit 1; } mv IAMCli-$(DEB_UPSTREAM_VERSION).tar.gz iamcli_$(DEB_UPSTREAM_VERSION).orig.tar.gz rm -f iamcli.zip @echo wrote iamcli_$(DEB_UPSTREAM_VERSION).orig.tar.gz debian/README.source0000644000000000000000000000203112160631467011347 0ustar This package uses the "3.0 (quilt)" source format. upstream packaging is available in bzr branches owned by the awstools-dev team in launchpad (https://launchpad.net/~awstools-dev). The packaging bzr branch for this package is available at: lp:~awstools-dev/ubuntu//iamcli/ https://code.launchpad.net/~awstools-dev/ubuntu//iamcli/ For example: lp:~awstools-dev/ubuntu/natty/iamcli/natty https://code.launchpad.net/~awstools-dev/ubuntu/natty/iamcli/natty There is a ppa maintained at https://launchpad.net/~awstools-dev/+archive/awstools That contains development versions of the package, and backports to stable releases. The scripts in bin/ can be run in place and with patches applied by setting the AWS_IAM_HOME environment variable to the top level source directory. Ie: chmod +x bin/*; chmod -x bin/*.cmd AWS_IAM_HOME=$PWD ./bin/iam-groupaddpolicy The Makefile modifies the default AWS_IAM_HOME to be /usr/lib/iamcli so that setting AWS_IAM_HOME is not required when the package is installed. debian/patches/0000755000000000000000000000000012160632144010614 5ustar debian/patches/series0000644000000000000000000000006212160631467012036 0ustar add-makefile.patch launcher-script-cleanups.patch debian/patches/add-makefile.patch0000644000000000000000000000452212160631467014152 0ustar --- /dev/null +++ b/Makefile @@ -0,0 +1,60 @@ +NAME = iamcli +libdir = /usr/lib/$(NAME) +LIBDIR = $(DESTDIR)$(libdir) +BINDIR = $(DESTDIR)/usr/bin +MANDIR = $(DESTDIR)/usr/share/man/man1 +DOCDIR = $(DESTDIR)/usr/share/doc/$(NAME) + +binprogs := $(shell cd bin && for x in *; do case $$x in (*.cmd) continue;; esac; echo $$x; done ) + +# SYSLIBS_FILE is a path to a file that contains lines of data with +# - a dir from lib/ that is replaced by a packaged java library dependency +# - the list of jars in /usr/share/java that will need to be added to classpath +SYSLIBS_FILE = debian/shared-java-libs + +# sysjars: list of jars provided by shared java libraries +# binjars: list of jars under lib/ that are copied from source package +sysjars := $(shell [ -n "$(SYSLIBS_FILE)" ] || exit 0; h="\#"; \ + while read binjar pkg sysjar; do \ + [ "$${binjar\#$${h}}" = "$${binjar}" ] || continue; \ + echo $${sysjar}; done < $(SYSLIBS_FILE); ) +binjars_replaced := $(shell [ -n "$(SYSLIBS_FILE)" ] || exit 0; h="\#"; \ + while read binjar pkg sysjar; do \ + [ "$${binjar\#$${h}}" = "$${binjar}" ] || continue; \ + echo $${binjar}; done < $(SYSLIBS_FILE); ) + +binjars := $(shell cd lib && \ + for binjar in $$(find * -name "*.jar"); do for sysjar in $(binjars_replaced); do \ + [ $${binjar} = "$${sysjar}" ] && continue 2; done; \ + echo $$binjar; done ) + +JAVA_SHARED_CLASSPATH = $(shell for f in $(sysjars); do l=$${l:+$${l}:}/usr/share/java/$$f; done; echo $$l) + +manpages := $(binprogs:%=man/%.1) + +build: + true + +debug: + @echo JAVA_SHARED_CLASSPATH=$(JAVA_SHARED_CLASSPATH) + @echo binjars=$(binjars) + @echo sysjars=$(sysjars) + +install: + mkdir -p "$(BINDIR)" "$(LIBDIR)" "$(DOCDIR)" + cd bin && cp $(binprogs) "$(BINDIR)" + cd "$(BINDIR)" && sed -i 's,@@AWS_IAM_HOME@@,$(libdir),' $(binprogs) + [ -n "$(JAVA_SHARED_CLASSPATH)" ] || exit 0; \ + cd "$(BINDIR)" && sed -i 's,@@JAVA_SHARED_CLASSPATH@@,$(JAVA_SHARED_CLASSPATH),' $(binprogs) + cd "$(BINDIR)" && chmod 755 $(binprogs) + @cd lib && set -e && for j in $(binjars); do \ + mkdir -p "$(LIBDIR)/$${j%/*}" && \ + cp "$$j" "$(LIBDIR)/$${j%/*}"; done + cp aws-credential.template README.txt "$(DOCDIR)" + +clean: + cd "$(BINDIR)" && rm -f $(binprogs) || : + cd "$(LIBDIR)" && for j in $(binjars); do \ + [ -f "$${j}" ] || continue; \ + rm -f "$${j}" && \ + { rmdir "$${j%/*}" || :; }; done; : debian/patches/launcher-script-cleanups.patch0000644000000000000000000036250112160631467016566 0ustar Description: makes a set of changes to all the bin/* programs. - do not use JAVA_HOME, simply invoke 'java' - exec java, so that the launcher script doesn't wait around for its return - replaces the way the classpath was set up. This allows us to work with the installed path (/usr/lib/iamcli/) where the existing path required a 'lib' on the end of the path. - sets default path to @@AWS_IAM_HOME@@ which will then be set correctly on make install. Note, it will still function in the build directory by setting AWS_IAM_HOME correctly before invoking - support using system jars if AWS_IAM_JAVA_SHARED_CLASSPATH is set or '@@JAVA_SHARED_CLASS_PATH@@' is replaced in the program. . Each of the launcher scripts contain identical source except for the last line. You can verify that by doing something like: for f in bin/*; do [ "$f" = "${f%.cmd}" ] || continue ; head -n -1 $f > $f.out done All of the '.out' files will be identical . The patch can be updated with the following: files=$(for f in bin/*; do case "${f##*/}" in (*.cmd) continue;; esac echo $f; done) patch=debian/patches/launcher-script-cleanups.patch quilt header ${patch##*/} > header.tmp quilt delete ${patch##*/} rm $patch quilt new ${patch##*/} quilt add $files for f in $files; do tail -n 1 "${f}" > tmpf cat debian/launcher-header debian/launcher-logic tmpf > "${f}" done quilt refresh # replace header quilt header ${patch##*/} -r < header.tmp rm -f header.tmp tmpf Origin: Scott Moser --- a/bin/iam-accountaliascreate +++ b/bin/iam-accountaliascreate @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.AccountAliasCreateView ${1+"$@"} --- a/bin/iam-accountaliasdelete +++ b/bin/iam-accountaliasdelete @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.AccountAliasDeleteView ${1+"$@"} --- a/bin/iam-accountaliaslist +++ b/bin/iam-accountaliaslist @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.AccountAliasListView ${1+"$@"} --- a/bin/iam-accountdelpasswordpolicy +++ b/bin/iam-accountdelpasswordpolicy @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.AccountDelPasswordPolicyView ${1+"$@"} --- a/bin/iam-accountgetpasswordpolicy +++ b/bin/iam-accountgetpasswordpolicy @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.AccountGetPasswordPolicyView ${1+"$@"} --- a/bin/iam-accountgetsummary +++ b/bin/iam-accountgetsummary @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.AccountGetSummaryView ${1+"$@"} --- a/bin/iam-accountmodpasswordpolicy +++ b/bin/iam-accountmodpasswordpolicy @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.AccountModPasswordPolicyView ${1+"$@"} --- a/bin/iam-groupaddpolicy +++ b/bin/iam-groupaddpolicy @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.GroupAddPolicyView ${1+"$@"} --- a/bin/iam-groupadduser +++ b/bin/iam-groupadduser @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.GroupAddUserView ${1+"$@"} --- a/bin/iam-groupcreate +++ b/bin/iam-groupcreate @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.GroupCreateView ${1+"$@"} --- a/bin/iam-groupdel +++ b/bin/iam-groupdel @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.GroupDelView ${1+"$@"} --- a/bin/iam-groupdelpolicy +++ b/bin/iam-groupdelpolicy @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.GroupDelPolicyView ${1+"$@"} --- a/bin/iam-grouplistbypath +++ b/bin/iam-grouplistbypath @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.GroupListByPathView ${1+"$@"} --- a/bin/iam-grouplistpolicies +++ b/bin/iam-grouplistpolicies @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.GroupListPoliciesView ${1+"$@"} --- a/bin/iam-grouplistusers +++ b/bin/iam-grouplistusers @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.GroupListUsersView ${1+"$@"} --- a/bin/iam-groupmod +++ b/bin/iam-groupmod @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.GroupModView ${1+"$@"} --- a/bin/iam-groupremoveuser +++ b/bin/iam-groupremoveuser @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.GroupRemoveUserView ${1+"$@"} --- a/bin/iam-groupuploadpolicy +++ b/bin/iam-groupuploadpolicy @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.GroupUploadPolicyView ${1+"$@"} --- a/bin/iam-instanceprofileaddrole +++ b/bin/iam-instanceprofileaddrole @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.InstanceProfileAddRoleView ${1+"$@"} --- a/bin/iam-instanceprofilecreate +++ b/bin/iam-instanceprofilecreate @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.InstanceProfileCreateView ${1+"$@"} --- a/bin/iam-instanceprofiledel +++ b/bin/iam-instanceprofiledel @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.InstanceProfileDelView ${1+"$@"} --- a/bin/iam-instanceprofilegetattributes +++ b/bin/iam-instanceprofilegetattributes @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.InstanceProfileGetAttributesView ${1+"$@"} --- a/bin/iam-instanceprofilelistbypath +++ b/bin/iam-instanceprofilelistbypath @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.InstanceProfileListByPathView ${1+"$@"} --- a/bin/iam-instanceprofilelistforrole +++ b/bin/iam-instanceprofilelistforrole @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.InstanceProfileListForRoleView ${1+"$@"} --- a/bin/iam-instanceprofileremoverole +++ b/bin/iam-instanceprofileremoverole @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.InstanceProfileRemoveRoleView ${1+"$@"} --- a/bin/iam-roleaddpolicy +++ b/bin/iam-roleaddpolicy @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.RoleAddPolicyView ${1+"$@"} --- a/bin/iam-rolecreate +++ b/bin/iam-rolecreate @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.RoleCreateView ${1+"$@"} --- a/bin/iam-roledel +++ b/bin/iam-roledel @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.RoleDelView ${1+"$@"} --- a/bin/iam-roledelpolicy +++ b/bin/iam-roledelpolicy @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.RoleDelPolicyView ${1+"$@"} --- a/bin/iam-rolegetattributes +++ b/bin/iam-rolegetattributes @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.RoleGetAttributesView ${1+"$@"} --- a/bin/iam-rolelistbypath +++ b/bin/iam-rolelistbypath @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.RoleListByPathView ${1+"$@"} --- a/bin/iam-rolelistpolicies +++ b/bin/iam-rolelistpolicies @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.RoleListPoliciesView ${1+"$@"} --- a/bin/iam-roleupdateassumepolicy +++ b/bin/iam-roleupdateassumepolicy @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.RoleUpdateAssumePolicyView ${1+"$@"} --- a/bin/iam-roleuploadpolicy +++ b/bin/iam-roleuploadpolicy @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.RoleUploadPolicyView ${1+"$@"} --- a/bin/iam-servercertdel +++ b/bin/iam-servercertdel @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.ServerCertDelView ${1+"$@"} --- a/bin/iam-servercertgetattributes +++ b/bin/iam-servercertgetattributes @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.ServerCertGetAttributesView ${1+"$@"} --- a/bin/iam-servercertlistbypath +++ b/bin/iam-servercertlistbypath @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.ServerCertListByPathView ${1+"$@"} --- a/bin/iam-servercertmod +++ b/bin/iam-servercertmod @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.ServerCertModView ${1+"$@"} --- a/bin/iam-servercertupload +++ b/bin/iam-servercertupload @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.ServerCertUploadView ${1+"$@"} --- a/bin/iam-useraddcert +++ b/bin/iam-useraddcert @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.UserAddCertView ${1+"$@"} --- a/bin/iam-useraddkey +++ b/bin/iam-useraddkey @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.UserAddKeyView ${1+"$@"} --- a/bin/iam-useraddloginprofile +++ b/bin/iam-useraddloginprofile @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.UserAddLoginProfileView ${1+"$@"} --- a/bin/iam-useraddpolicy +++ b/bin/iam-useraddpolicy @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.UserAddPolicyView ${1+"$@"} --- a/bin/iam-userchangepassword +++ b/bin/iam-userchangepassword @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.UserChangePasswordView ${1+"$@"} --- a/bin/iam-usercreate +++ b/bin/iam-usercreate @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.UserCreateView ${1+"$@"} --- a/bin/iam-userdeactivatemfadevice +++ b/bin/iam-userdeactivatemfadevice @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.UserDeactivateMFADeviceView ${1+"$@"} --- a/bin/iam-userdel +++ b/bin/iam-userdel @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.UserDelView ${1+"$@"} --- a/bin/iam-userdelcert +++ b/bin/iam-userdelcert @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.UserDelCertView ${1+"$@"} --- a/bin/iam-userdelkey +++ b/bin/iam-userdelkey @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.UserDelKeyView ${1+"$@"} --- a/bin/iam-userdelloginprofile +++ b/bin/iam-userdelloginprofile @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.UserDelLoginProfileView ${1+"$@"} --- a/bin/iam-userdelpolicy +++ b/bin/iam-userdelpolicy @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.UserDelPolicyView ${1+"$@"} --- a/bin/iam-userenablemfadevice +++ b/bin/iam-userenablemfadevice @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.UserEnableMFADeviceView ${1+"$@"} --- a/bin/iam-usergetattributes +++ b/bin/iam-usergetattributes @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.UserGetAttributesView ${1+"$@"} --- a/bin/iam-usergetloginprofile +++ b/bin/iam-usergetloginprofile @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.UserGetLoginProfileView ${1+"$@"} --- a/bin/iam-userlistbypath +++ b/bin/iam-userlistbypath @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.UserListByPathView ${1+"$@"} --- a/bin/iam-userlistcerts +++ b/bin/iam-userlistcerts @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.UserListCertsView ${1+"$@"} --- a/bin/iam-userlistgroups +++ b/bin/iam-userlistgroups @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.UserListGroupsView ${1+"$@"} --- a/bin/iam-userlistkeys +++ b/bin/iam-userlistkeys @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.UserListKeysView ${1+"$@"} --- a/bin/iam-userlistmfadevices +++ b/bin/iam-userlistmfadevices @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.UserListMFADevicesView ${1+"$@"} --- a/bin/iam-userlistpolicies +++ b/bin/iam-userlistpolicies @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.UserListPoliciesView ${1+"$@"} --- a/bin/iam-usermod +++ b/bin/iam-usermod @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.UserModView ${1+"$@"} --- a/bin/iam-usermodcert +++ b/bin/iam-usermodcert @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.UserModCertView ${1+"$@"} --- a/bin/iam-usermodkey +++ b/bin/iam-usermodkey @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.UserModKeyView ${1+"$@"} --- a/bin/iam-usermodloginprofile +++ b/bin/iam-usermodloginprofile @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.UserModLoginProfileView ${1+"$@"} --- a/bin/iam-userresyncmfadevice +++ b/bin/iam-userresyncmfadevice @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.UserResyncMFADeviceView ${1+"$@"} --- a/bin/iam-useruploadpolicy +++ b/bin/iam-useruploadpolicy @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.UserUploadPolicyView ${1+"$@"} --- a/bin/iam-virtualmfadevicecreate +++ b/bin/iam-virtualmfadevicecreate @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.VirtualMFADeviceCreateView ${1+"$@"} --- a/bin/iam-virtualmfadevicedel +++ b/bin/iam-virtualmfadevicedel @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.VirtualMFADeviceDelView ${1+"$@"} --- a/bin/iam-virtualmfadevicelist +++ b/bin/iam-virtualmfadevicelist @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/sh # Copyright 2006-2011 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the # Amazon Software License (the "License"). You may not use this file except in compliance with the License. A copy of the @@ -6,26 +6,13 @@ # IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. +AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} +[ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || + SERVICE_HOME="${AWS_IAM_HOME}" +for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done -if [ -n "${JAVA_HOME:+x}" ]; then - JAVA_COMMAND=${JAVA_HOME}/bin/java -else - echo JAVA_HOME is not set - exit 1 -fi +jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} +[ "${jshared#@@}" = "${jshared}" ] || jshared="" -if [ -n "${AWS_IAM_HOME:+x}" ]; then - SERVICE_HOME=${AWS_IAM_HOME} -else - echo AWS_IAM_HOME is not set - exit 1 -fi - -"${JAVA_COMMAND}" ${AWS_IAM_JVM_OPTS} -cp "${SERVICE_HOME}/lib/apache-log4j-1.2.15/*\ -:${SERVICE_HOME}/lib/args4j-2.0.10/*\ -:${SERVICE_HOME}/lib/commons-codec-1.3/*\ -:${SERVICE_HOME}/lib/commons-httpclient-4.1.1/*\ -:${SERVICE_HOME}/lib/saxonhe-9.0.2j/*\ -:${SERVICE_HOME}/lib/commons-logging-1.1.1/*\ -:${SERVICE_HOME}/lib/aws-iam-cli/*" \ +exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ com.amazonaws.services.auth.identity.cli.view.VirtualMFADeviceListView ${1+"$@"} debian/launcher-logic0000644000000000000000000000063112160631467012013 0ustar AWS_IAM_HOME=${AWS_IAM_HOME:-"@@AWS_IAM_HOME@@"} [ -d "${AWS_IAM_HOME}/lib" ] && SERVICE_HOME="${AWS_IAM_HOME}/lib" || SERVICE_HOME="${AWS_IAM_HOME}" for j in "${SERVICE_HOME}"/*/*.jar; do cp="${cp:+${cp}:}${j}"; done jshared=${AWS_IAM_JAVA_SHARED_CLASSPATH:-"@@JAVA_SHARED_CLASSPATH@@"} [ "${jshared#@@}" = "${jshared}" ] || jshared="" exec java ${AWS_IAM_JVM_OPTS} -cp "${cp}${jshared:+:${jshared}}" \ debian/repack-zip0000755000000000000000000000230712160631467011171 0ustar #!/bin/sh # # repack a zip file, as reproducibly as possible # downloads the zip, extract it, create tarball # with members in the same order as original zip file # but with ownership root:root and perms a+X cleanup() { [ -d "$TEMP_D" ] || rm -Rf "$TEMP_D" } fail() { echo "$@" 1>&2; exit 1; } TEMP_D=$(mktemp -d) trap cleanup EXIT start_d=$PWD [ $# -eq 1 ] || { echo "must give input zip file"; exit 1; } input=${1} zip=${input##*/} case "$input" in http://*|https://*|ftp://*) echo "downloading ${input}" wget -q "$input" -O "$TEMP_D/${zip}" ;; *) cp "$input" "${TEMP_D}/${zip}";; esac [ $? -eq 0 ] || fail "failed to get ${input} to tempdir" cd "$TEMP_D" unzip -a "$zip" > .zip.contents || fail "failed to unzip ${zip}" for f in *; do [ "$f" = "$zip" ] && continue [ -z "$tld" ] || fail "multiple top level content in ${zip} [$f]" tld=$f done ver=${tld#*-} awk '($1 == "creating:" || $1 == "inflating:") { print $2 }' \ .zip.contents > contents GZIP='-n -9' tar --owner=root --group=root --mode=a+rX \ --no-recursion --files-from contents \ -czf "${start_d}/${tld}.tar.gz" || fail "failed to create ${tld}.tar.gz" echo "created ${tld}.tar.gz from ${input}" 1>&2 debian/control0000644000000000000000000000127612160631647010605 0ustar Source: iamcli Section: admin Priority: extra Maintainer: Scott Moser Build-Depends: debhelper (>= 7), quilt Standards-Version: 3.9.3 Homepage: http://aws.amazon.com/developertools/AWS-Identity-and-Access-Management/4143 Package: iamcli Architecture: all Depends: default-jre-headless | java6-runtime-headless, libcommons-logging-java, libhttpclient-java, libhttpcore-java, liblog4j1.2-java, ${misc:Depends} Description: AWS Identity Access Management Command Line Toolkit The Command Line Toolkit for the Amazon Web Services (AWS) Identity and Access Management (IAM) Service enables users to execute IAM APIs with simple commands. debian/compat0000644000000000000000000000000212160631467010372 0ustar 7