blacklist certain sensitive fields and relations as search arguments

see: #5465
see: #5478
This commit is contained in:
Ryan Petrello
2017-02-21 12:18:40 -05:00
parent 0a5b43acae
commit d24fb32358
13 changed files with 99 additions and 32 deletions

View File

@@ -1284,11 +1284,11 @@ class CustomInventoryScript(CommonModelNameNotUnique, ResourceMixin):
unique_together = [('name', 'organization')]
ordering = ('name',)
script = models.TextField(
script = prevent_search(models.TextField(
blank=True,
default='',
help_text=_('Inventory script contents'),
)
))
organization = models.ForeignKey(
'Organization',
related_name='custom_inventory_scripts',