mirror of
https://github.com/ansible/awx.git
synced 2026-05-20 07:17:40 -02:30
Adding new privilege escalation methods from core
This commit is contained in:
@@ -47,6 +47,11 @@ class Migration(migrations.Migration):
|
|||||||
name='uuid',
|
name='uuid',
|
||||||
field=models.CharField(max_length=40),
|
field=models.CharField(max_length=40),
|
||||||
),
|
),
|
||||||
|
migrations.AlterField(
|
||||||
|
model_name='credential',
|
||||||
|
name='become_method',
|
||||||
|
field=models.CharField(default=b'', help_text='Privilege escalation method.', max_length=32, blank=True, choices=[(b'', 'None'), (b'sudo', 'Sudo'), (b'su', 'Su'), (b'pbrun', 'Pbrun'), (b'pfexec', 'Pfexec'), (b'dzdo', 'DZDO'), (b'pmrun', 'Pmrun')]),
|
||||||
|
),
|
||||||
# Add Workflows
|
# Add Workflows
|
||||||
migrations.AlterField(
|
migrations.AlterField(
|
||||||
model_name='unifiedjob',
|
model_name='unifiedjob',
|
||||||
|
|||||||
@@ -50,6 +50,8 @@ class Credential(PasswordFieldsModel, CommonModelNameNotUnique, ResourceMixin):
|
|||||||
('su', _('Su')),
|
('su', _('Su')),
|
||||||
('pbrun', _('Pbrun')),
|
('pbrun', _('Pbrun')),
|
||||||
('pfexec', _('Pfexec')),
|
('pfexec', _('Pfexec')),
|
||||||
|
('dzdo', _('DZDO')),
|
||||||
|
('pmrun', _('Pmrun')),
|
||||||
#('runas', _('Runas')),
|
#('runas', _('Runas')),
|
||||||
]
|
]
|
||||||
|
|
||||||
|
|||||||
@@ -1743,6 +1743,10 @@ class RunAdHocCommand(BaseTask):
|
|||||||
d[re.compile(r'^pfexec password.*:\s*?$', re.M)] = 'become_password'
|
d[re.compile(r'^pfexec password.*:\s*?$', re.M)] = 'become_password'
|
||||||
d[re.compile(r'^RUNAS password.*:\s*?$', re.M)] = 'become_password'
|
d[re.compile(r'^RUNAS password.*:\s*?$', re.M)] = 'become_password'
|
||||||
d[re.compile(r'^runas password.*:\s*?$', re.M)] = 'become_password'
|
d[re.compile(r'^runas password.*:\s*?$', re.M)] = 'become_password'
|
||||||
|
d[re.compile(r'^DZDO password.*:\s*?$', re.M)] = 'become_password'
|
||||||
|
d[re.compile(r'^dzdo password.*:\s*?$', re.M)] = 'become_password'
|
||||||
|
d[re.compile(r'^PMRUN password.*:\s*?$', re.M)] = 'become_password'
|
||||||
|
d[re.compile(r'^pmrun password.*:\s*?$', re.M)] = 'become_password'
|
||||||
d[re.compile(r'^SSH password:\s*?$', re.M)] = 'ssh_password'
|
d[re.compile(r'^SSH password:\s*?$', re.M)] = 'ssh_password'
|
||||||
d[re.compile(r'^Password:\s*?$', re.M)] = 'ssh_password'
|
d[re.compile(r'^Password:\s*?$', re.M)] = 'ssh_password'
|
||||||
return d
|
return d
|
||||||
|
|||||||
Reference in New Issue
Block a user