def auth_and_licensing_logic()

in functions/source/LicenseVerificationAndTokenGenerator/lambda_function.py [0:0]


def auth_and_licensing_logic(event, context):
      sanitized_event = copy.deepcopy(event)
      sanitized_event['ResourceProperties']['BoomiPassword'] = "<Redacted>"
      logger.info('Received event: %s' % json.dumps(sanitized_event))

      # Sanity Checking
      parameters = event['ResourceProperties']
      username, password, account_id, token_type, token_timeout = _verify_required_parameters(parameters)

      # Verify licensing
      # NOTE: Removing as the Boomi APIs don't behave in a way that was previously assumed.
      # No easy way to accurately determine licensing usage. 2021/05/25
      #_verify_boomi_licensing(username, password, account_id)
      if token_type:
          # Generate install token
          token = _generate_install_token(username, password, account_id, token_type, token_timeout)
          helper.Data['InstallToken'] = token