Getting "Invalid client secret is provided" error while setting up Splunk with Azure Event Hub - splunk

I am getting the following error while configuring Splunk with Azure Event Hub.
2021-04-23 10:12:17,141 level=WARNING pid=xxxxxxx tid=Thread-2
logger=azure.eventhub._eventprocessor.event_processor
pos=event_processor.py:_load_balancing:281 | EventProcessor instance
'2ea6353e-ee45-4a4e-b173-5f82ae79707c' of eventhub
'insights-activity-logs' consumer group '$Default'. An error occurred
while load-balancing and claiming ownership. The exception is
EventHubError("Unexpected response '{'error': 'invalid_client',
'error_description': 'AADSTS7000215: Invalid client secret is
provided.\r\nTrace
ID:xxxxxxx-c913-420f-8dfb-5169faed3800\r\nCorrelation ID:
xxxxxxxx-81b2-4436-9d25-13e38ec15d9d\r\nTimestamp: 2021-04-23
02:12:10Z', 'error_codes': [7000215], 'timestamp': '2021-04-23
02:12:10Z', 'trace_id': 'xxxxxxxxx-c913-420f-8dfb-5169faed3800',
'correlation_id': 'xxxxxxxx-81b2-4436-9d25-13e38ec15d9d', 'error_uri':
'https://login.microsoftonline.com/error?code=7000215'}'\nUnexpected
response '{'error': 'invalid_client', 'error_description':
'AADSTS7000215: Invalid client secret is provided.\r\nTrace ID:
xxxxxxx-c913-420f-8dfb-5169faed3800\r\nCorrelation ID:
xxxxxxx-81b2-4436-9d25-13e38ec15d9d\r\nTimestamp: 2021-04-23
02:12:10Z', 'error_codes': [7000215], 'timestamp': '2021-04-23
02:12:10Z', 'trace_id': 'xxxxxxxxx-c913-420f-8dfb-5169faed3800',
'correlation_id': 'xxxxxxxxxx-81b2-4436-9d25-13e38ec15d9d',
'error_uri':
'https://login.microsoftonline.com/error?code=7000215'}'"). Retrying
after 10.408012031827356 seconds
I am referring to the following tutorials:
https://www.splunk.com/en_us/blog/tips-and-tricks/splunking-microsoft-azure-monitor-data-part-1-azure-setup.html
https://www.splunk.com/en_us/blog/tips-and-tricks/splunking-microsoft-azure-monitor-data-part-2-splunk-setup.html
From my understanding, it is that we will have to generate a Azure AD application and set its permission for resource management and here, I am making use of it to enable Splunk to access the activity logs to my Event Hub. I have done setting up an AD application and added the role assignment to the AD application, after that, generated a client secret as mentioned in the tutorial. I am subscribing to Azure for Student, will this be the cause of getting this error as I have limited privileges?

I've faced the same error you described, as it turns out, Splunk Add-on for Microsoft Cloud Services version 4.1.2 has a known issues as described in the release note.
enter image description here
Download version 4.1.1 and force installation solved the issue for me

Related

How to troubleshoot enabling API services in GCP using gcloud

When executing terraform apply, I get this error where I am being asked to enable IAM API for my project.
Error: Error creating service account: googleapi: Error 403: Identity and Access
Management (IAM) API has not been used in project [PROJECT-NUMBER] before or it is
disabled. Enable it by visiting
https://console.developers.google.com/apis/api/iam.googleapis.com/overview?
project=[PROJECT-NUMBER] then retry. If you enabled this API recently, wait a few
minutes for the action to propagate to our systems and retry.,
accessNotConfigured
When I attempt to enable it using gcloud, the service enable just hangs. Is there any way to get more information?
According to the Google Dashboard, everything is green.
I am also seeing the same issue using the UI.
$ gcloud services enable iam.googleapis.com container.googleapis.com
Error Message
ERROR: gcloud crashed (WaitException): last_result=True, last_retrial=178, time_passed_ms=1790337,time_to_wait=10000
Add --log-http to (any) gcloud command to get detailed logging of the underlying API calls. These may provide more details on where the error occurs.
You may wish to explicitly reference the project too: --project=....
Does IAM need to be enabled? It's such a foundational service, I'm surprised anything would work if it weren't enabled.

Invalid credentials error for Cloudhub connector

I configured cloudhub connector using anypoint credentials to create notification for time out error. when I tried to test application, I am getting an error as
Invalid Credentials" error type: CLOUDHUB-CONNECTIVITY
The below code is how I configured it in Mule 4. Is this related to permissions of my anypoint account?
I too was getting this issue and through trial and error it appears that the user raising the notification needs at minimum the 'Read Applications' permission on the environment in question.
In Mule 4 you can also optionally specify the environment id in the config; using the system property ${environment.id} if you want it to apply to the environment where your app is deployed, eg:
<cloudhub:config name="CloudHub_Config" doc:name="CloudHub Config">
<cloudhub:connection username="${cloudhub.username}" password="${cloudhub.password}" environment="${environment.id}" />
</cloudhub:config>
If this is environment attribute is omitted, I believe it uses the one defined as default in Anypoint Platform.

Failed to load APIs - Error 403 on Azure Mobile Service

I have staging Azure Mobile Service that has suddenly stopped working and started to report errors when called by other apps.
The direct Mobile Service URL is reporting "Error 403 - This web app is stopped." error at https://b8akjsms2-st.azure-mobile.net/ I am also unable to access the api from the Azure portal which throw this message:
Failed to download zip file for path '/site/repository/service/api/' in Mobile Service 'b8akJSMS2-st' If you contact a support representative please include this correlation identifier: 4ebe635c-bbb7-af06-a71a-532f0467e828, the time of error: 2016-06-10 11:40:36Z, and the error id: ZE6.
How can I resolve this issue?
I can see that the service is on the free tier and is over CPU quota limits. These will reset at midnight UTC each day (5pm PST). Please feel free to contact us if you have any questions.

Registering new devices to Azure IOT hub

Just simple question:
I have created a new Service bus, Event hub and some shared access tokens with all rights, but registering a new device with iothub-explorer fails to 'unauthorized' message in Azure.
[tuomas#raspberry ~]$ iothub-explorer login "HostName=mynew-iot.servicebus.windows.net;SharedAccessKeyName=mynewdevice-1;SharedAccessKey=NptRRzI9mhiXO2QKuhZq47iY24A7cbtxRpUDSQO5aSI=" --connection-string
Session started, expires Tue Apr 12 2016 20:02:13 GMT+0300 (EEST)
[tuomas#raspberry ~]$ iothub-explorer "HostName=mynew-iot.servicebus.windows.net;SharedAccessKeyName=device-1;SharedAccessKey=NptRRzI9mhiXO2QKuhZq47iY24A7cbtxRpUDSQO5aSI=" create dummydev
Error Unauthorized
Any toughts?
With Thanks,
~T
I don't know if it's on purpose or not but the connection string in the second command doesn't match the one in the first one: the SharedAccessKeyName is different. Maybe it's just that.
If it's not just that, due to the way it's named I'm under the impression that you are using a device connection string when you should be using the service connection string (with a policy name in the SharedAccessKeyName field, such as the iothubowner). Whatever the policy is it should have the permissions to read and write to the registry. Unless you named such a policy "mynewdevice-1" ? One simple way to debug this is to use the iothubowner policy and associated key since it has full permissions.
Last thing, if you're using the "login" command, you don't need to specify the connectionstring again in subsequent commands (except to receive messages sent by devices, since this is done on the event hubs endpoint).
Thanks, I have really messed these old and new portals.
After creating a new Service bus and event hub in new portal I can register my devices. The rest .... new question perhaps...
With thanks.

What is root cause of getting debug log related to WL_AFHTTPRequestOperationManagerWrapper_PACKAGE

We are getting below logs in analytics console (client logs). Does any one has idea root cause behind this debug log.
Date Thursday, Mar 10, 2016, 12:35 AM
Application Name XYZAPP
Application Version 1.9.1
Operating System ios
Device ID BD39F272-D57F-45AC-AACE-3C0277BA796B
Device Model iPhone8,1
OS Version 9.2.1
Package WL_AFHTTPRequestOperationManagerWrapper_PACKAGE
Level Debug
Message Response Error : Request failed: forbidden (403)
A 403 means that no user is allowed to access that resource strictly FORBIDDEN. Not to be confused with a 401 which is UNAUTHORIZED (you just do not have the right credentials).
Unfortunately that is all we can determine from the error.
WLResourceReqeust uses WL_AFHTTPRequestOperationManagerWrapper_PACKAGE and all request made by the client is a ResourceRequest.
Putting a few things together my guess is that this comes from when a user is trying to authenticate with the server. Occasionally we (the mobilefirst server) returns a 403 which is will be logged in the analytics console if you are sending debug logs.