Returns ACL for a specific user. Returns None if eauth doesn't provide any for the user. I. e. None means: use acl declared in master config.
(self, load)
| 161 | return False |
| 162 | |
| 163 | def __get_acl(self, load): |
| 164 | """ |
| 165 | Returns ACL for a specific user. |
| 166 | Returns None if eauth doesn't provide any for the user. I. e. None means: use acl declared |
| 167 | in master config. |
| 168 | """ |
| 169 | if "eauth" not in load: |
| 170 | return None |
| 171 | mod = self.opts["eauth_acl_module"] |
| 172 | if not mod: |
| 173 | mod = load["eauth"] |
| 174 | fstr = f"{mod}.acl" |
| 175 | if fstr not in self.auth: |
| 176 | return None |
| 177 | fcall = salt.utils.args.format_call( |
| 178 | self.auth[fstr], load, expected_extra_kws=AUTH_INTERNAL_KEYWORDS |
| 179 | ) |
| 180 | try: |
| 181 | return self.auth[fstr](*fcall["args"], **fcall["kwargs"]) |
| 182 | except Exception as e: # pylint: disable=broad-except |
| 183 | log.debug("Authentication module threw %s", e) |
| 184 | return None |
| 185 | |
| 186 | def __process_acl(self, load, auth_list): |
| 187 | """ |
no test coverage detected