0
  	   0     h      202:1
  	   0  
   355 c    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html><head>
<title>404 Not Found</title>
</head><body>
<h1>Not Found</h1>
<p>The requested URL was not found on this server.</p>
<p>Additionally, a 404 Not Found
error was encountered while trying to use an ErrorDocument to handle the request.</p>
</body></html>
  "   l=J*e8.2꘴oh      4:12
  #   .a=J*e8yLZ7 \    
Xc           @   sV   d  d l  m Z d  d l m Z m Z m Z d  d l m Z d e f d     YZ d S(   i(   t   Arg(   t
   IAMRequestt
   AS_ACCOUNTt   arg_user(   t   prompt_for_passwordt   CreateLoginProfilec           B   sD   e  Z d  Z e d d  e d d d d d d e g Z d   Z RS(	   s(   Create a password for the specified usert   helps4   name of the user to create a password for (required)s   -ps
   --passwordt   destt   Passwordsj   the new password.  If unspecified, the new password
                        will be read from the console.c         C   sG   t  j |   |  j d d  k rC |  j j d  t   |  j d <n  d  S(   NR   s   no password supplied; prompting(   R   t	   configuret   argst   Nonet   logt   infoR   t   params(   t   self(    (    sM   /usr/lib/python2.7/site-packages/euca2ools/commands/iam/createloginprofile.pyR	   )   s    (   t   __name__t
   __module__t   DESCRIPTIONR   R    R   t   ARGSR	   (    (    (    sM   /usr/lib/python2.7/site-packages/euca2ools/commands/iam/createloginprofile.pyR       s   	N(	   t   requestbuilderR    t   euca2ools.commands.iamR   R   R   t   euca2ools.utilR   R   (    (    (    sM   /usr/lib/python2.7/site-packages/euca2ools/commands/iam/createloginprofile.pyt   <module>   s     "   lY>eJuA3pjbѿ/; 	S    # Copyright 2009-2015 Eucalyptus Systems, Inc.
#
# Redistribution and use of this software 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.

from requestbuilder import Arg

from euca2ools.commands.iam import IAMRequest, AS_ACCOUNT, arg_user


class GetLoginProfile(IAMRequest):
    DESCRIPTION = 'Verify that a user has a password'
    ARGS = [arg_user(
                help='user owning the password to check (required)'),
            Arg('--verbose', action='store_true', route_to=None,
                help="print extra info about the user's password"),
            AS_ACCOUNT]

    def print_result(self, result):
        # If we've managed to get to this point, we already know the user has
        # a login profile.
        user_name = result['LoginProfile'].get('UserName')
        print 'Login Profile Exists for User', user_name
        if self.args['verbose']:
            create_date = re