Azure-Sentinel icon indicating copy to clipboard operation
Azure-Sentinel copied to clipboard

Doubt about using Codeless with Session authType

Open cupello opened this issue 3 years ago • 3 comments

Hello people!

I need to login in an application and get the session id cookie to work with their API (yes... not good). I was trying to do something like this:

"pollingConfig": { ... "auth": { "authType": "Session", "IsPostPayloadJson": true, "SessionLoginRequestUri": "https://{{placeHolder1}}:443/login.html", "QueryParameters": "{'username': '{{placeHolder2}}', 'password': '{{placeHolder3}}'}", "SessionIdName": "SESSIONID" }

But no success yet... Could anyone tell me if this is possible and provide some examples?

Thanks in advance.

cupello avatar Jun 21 '22 17:06 cupello

Thank you for submitting an Issue to the Azure Sentinel GitHub repo! You should expect an initial response to your Issue from the team within 5 business days. Note that this response may be delayed during holiday periods. For urgent, production-affecting issues please raise a support ticket via the Azure Portal.

github-actions[bot] avatar Jun 21 '22 17:06 github-actions[bot]

Thank you for submitting an Issue to the Azure Sentinel GitHub repo! You should expect an initial response to your Issue from the team within 5 business days. Note that this response may be delayed during holiday periods. For urgent, production-affecting issues please raise a support ticket via the Azure Portal.

github-actions[bot] avatar Nov 21 '22 05:11 github-actions[bot]

Thank you for submitting an Issue to the Azure Sentinel GitHub repo! You should expect an initial response to your Issue from the team within 5 business days. Note that this response may be delayed during holiday periods. For urgent, production-affecting issues please raise a support ticket via the Azure Portal.

github-actions[bot] avatar Jan 10 '23 12:01 github-actions[bot]

Thank you for submitting an Issue to the Azure Sentinel GitHub repo! You should expect an initial response to your Issue from the team within 5 business days. Note that this response may be delayed during holiday periods. For urgent, production-affecting issues please raise a support ticket via the Azure Portal.

github-actions[bot] avatar Mar 20 '23 12:03 github-actions[bot]

To log in to an application and obtain the session ID cookie, you will typically need to follow these steps:

  1. Open the login page of the application in your web browser.
  2. Enter your login credentials (e.g., username and password).
  3. Submit the login form.
  4. Check if the application returns a session ID cookie in the HTTP response headers.

If the application returns a session ID cookie, you can extract the value of the cookie and use it in your subsequent API requests. Example:

import requests
#Set up the login data
login_data = {
'username': 'your_username',
'password': 'your_password'
}

#Send the login request
login_url = 'https://example.com/login'
response = requests.post(login_url, data=login_data)

#Check if the session ID cookie was returned
if 'sessionid' in response.cookies:
# Extract the value of the session ID cookie
session_id = response.cookies['sessionid']
print(f'Session ID: {session_id}')
else:
print('Login failed')

v-rbajaj avatar Mar 27 '23 06:03 v-rbajaj

@cupello, can you please provide some update on the above comment?

v-rbajaj avatar Apr 03 '23 12:04 v-rbajaj

Since we have not received a response in the last 5 days, we are closing your issue https://github.com/Azure/Azure-Sentinel/issues/5405 as per our standard operating procedures. If you still need support for this issue, feel free to re-open at any time. Thank you for your co-operation.

v-rbajaj avatar Apr 05 '23 06:04 v-rbajaj

Thank you for submitting an Issue to the Azure Sentinel GitHub repo! You should expect an initial response to your Issue from the team within 5 business days. Note that this response may be delayed during holiday periods. For urgent, production-affecting issues please raise a support ticket via the Azure Portal.

github-actions[bot] avatar Apr 05 '23 06:04 github-actions[bot]