MAPI_E_NETWORK_ERROR (not logged in) Redemption (using Outlook not MAPI standalone) - outlook-redemption

I have got my application working fine with the standalone MAPI (1.2.1 CDO) however after removing that and installing Outlook, I cannot get it working.
I get a MAPI_E_NETWORK_ERROR, which when I catch and return the exception message caught comes up with
System.Runtime.InteropServices.COMException: Not logged on. Please log on first
Do I have to do anything different to get this working with an outlook installation? This is thrown when doing
LogonExchangeMailbox(username, exserver)

MAPI_E_NETWORK_ERROR is a network access error. Is firewall active on that machine? Was your app added to the exclusion list?

It could also be the name of the exchange server not being correct. I had this issue as the old exchange server had been decommissioned so rather than being EXHANGE.ad.{company}.com it changed to just the new server name e.g. EXCHANGEABC12.

Also keep in mind that LogonExchangeMailbox connect using plain old RPC protocol. If you are connecting to Exchange 2013/2016 over RPC-over-HTTP, you need to use LogonHostedExchangeMailbox .

Related

How to use Google OAuth2.0 without out-of-band (OOB)

I have created new OAuth 2.0 Client IDs (application type = Desktop app). Then downloaded the OAuth client JSON file. Put the file into the folder where my code is looking. When I run the code locally on my PC it`s try to open following URL:
https://accounts.google.com/o/oauth2/auth?client_id={my_client_id}&redirect_uri=http%3A%2F%2Flocalhost%3A8080%2F&scope={my_scope}&access_type=offline&response_type=code
and that is what I expect. Since the downloaded OAuth client has the parameter "redirect_uris":["http://localhost"]. So I expected the same thing when I ran this same code on the ubuntu server, but nope. The URL it proposes me visit is
https://accounts.google.com/o/oauth2/auth?client_id={my_client_id}&redirect_uri=urn%3Aietf%3Awg%3Aoauth%3A2.0%3Aoob&scope={my_scope}&access_type=offline&response_type=code
And here is the problem, I don't understand what I have to do to make my server pass this authorization.
I already tried to manually change this parameter of redirect_uris before visiting the destination to the same one I had on my local computer - to http%3A%2F%2Flocalhost%3A8080%2F, but I got this error in the browser:
Who can help me? What should I do?
Developers using installed applications need to stitch to using IP flow.
Loopback IP address (macOS, Linux, Windows desktop)
A key point on that page is
To receive the authorization code using this URL, your application must be listening on the local web server.
So as directed you would use http://127.0.0.1:port or http://[::1]:port The fact that you are getting a page not found is working as intended as you just have not set up the local web server as directed in the documetnation.
The authorization code needed for authorization can still be found in the URL browser. Currently this is the only information we have from Google and there is no other solution.

Connecting using SnowSQL denied 403 error

I am trying to configure JDBC but kept getting the same error I am getting using snowsql:
250001 (08001): Failed to connect to DB. Verify the account name is correct: JG3409.canada-central.azure.snowflakecomputing.com:443. 000403: 403: HTTP 403: Forbidden
If the error message is unclear, enable logging using -o log_level=DEBUG and see the log to find out the cause. Contact support for further help.
Goodbye!
I have configured the config file, and I have double checked the account, company, region, reset password to only use alphanumeric.
I have used both forms of the URL
The only possibility is that I am using a trial account, but I can't imagine that this would limit external non-browser connections?
I use a simple user/password, I have whitelisted my IP and I don't have a problem with a proxy or a firewall. I can successfully connect using a browser.. using:
https://app.snowflake.com/canada-central.azure/jg63409
Important contents of the config file:
[connections]
accountname=JG3409
#accountname=uegxydq-pz20606
region=canada-central.azure
username=ASHSNOWFLAKE
any ideas?
Your account is not JG3409 but JG63409 based on this link:
https://app.snowflake.com/canada-central.azure/jg63409
Try in your browser:
https://jg63409.canada-central.azure.snowflakecomputing.com
I found out using snowcd that my computer could not connect via my home router.
When I used my personal hotspot on my (5G) phone, snowcd passed all the tests immediately. The problem then arose how to adjust the network security policy to allow a CIDR block of network addresses through since my phone uses a new address every time I connect, and I can't edit the policy to allow my phone while connected via my phone (for obvious reasons)
Catch 22
123.45.0.0/16 is not accepted in the new Snowflake UI, and 0.0.0.0 doesn't work for me, but the documentation gave me a clue.. the new UI doesn't separate by commas, so I switched to the old UI and voila!
Incidentally the OLD UI uses the same URL as SnowSQL so I picked up my error in my account number there as well (although I should have seen it earlier).
Diabolical but thanks #Sergiu too!

What has changed in Microsoft oAuth 2.0 implementation?

I have a web site that has been using Microsoft accounts for authentication for more than three years. It is a Node web app and is using the passport-windowslive package.
Lately, when users return from login.live.com after logging successfully using their Microsoft accounts, one of two types of errors is received, sometimes:
The provided value for the input parameter 'scope' is not valid. The target '«my web site domain»' does not exist.
or:
The provided value for the 'code' value is not valid. The code has expired.
The error is sporadic. I am unable to reproduce it on my development machine.
As the passport-windowslive package was last changed four years ago and my code has not changed for more than two years, the cause looks like it's at the Microsoft end. What has changed?
Update: The problem is getting worse. Previously, the problem could sometimes be overcome by using an incognito browser session or changing the browser. Now it's happening on all browsers. But I am still unable to reproduce the error when running on localhost (with no http).
Microsoft has changed how its applications can be used for oAuth. They must now be managed from Azure instead of apps.dev.microsoft.com or Microsoft Live.
Existing applications configured in apps.dev.microsoft.com will result in:
AADSTS700016: Application with identifier '000000xxxxxxx' was not found in the directory 'aaaaaaaa-bbbb-cccc-ddd-eeeeeeeeeeee'. This can happen if the application has not been installed by the administrator of the tenant or consented to by any user in the tenant. You may have sent your authentication request to the wrong tenant.
The passport-windowslive module somehow did not bubble up the error response.

IBM Worklight Adapter Invocation is throwing UNRESPONSIVE_HOST error

I have a very simple Worklight project that has two adapters. The first is talking to LinkedIn OAuth services to return an access token. The second takes the access token and calls LinkedIn's API services. The code works beautifully in project A. Project A is a larger project and includes a bunch of other things. I took the working adapters and copied them into project B. The adapters are word for word the same. The security settings between the projects are identical. Both adapters are deployed and I can verify them on the Worklight Console. However, in project B, when i call the oauth adapter i get the access token just fine, when i turn around and call the api adapter I get an error immediately saying that the host is unresponsive. UNRESPONSE_HOST "The service is currently not available".
Here is the logcat messages:
01-16 15:42:44.298: D/LinkedIn(3101): Request [http://192.168.245.1:10080/LinkedInDevWorks/apps/services/api/LinkedIn/android/query]
01-16 15:42:44.488: E/LinkedIn(3101): [http://192.168.245.1:10080/LinkedInDevWorks/apps/services/api/LinkedIn/android/query] Host is not responsive. Try to manually access the URL through the android emulator browser to verify connectivity.
I'm running out of ideas...
I looked at this article: http://www.ibm.com/developerworks/websphere/techjournal/1212_paris/1212_paris.html on adapter error messages but the settings between the two projects are identical so it's odd that it works on one and not the other.
I am running worklight 6.0
I still haven't found a solution to this problem but I wanted to post the workaround as an answer for others facing a similar problem:
"When i call the second adapter within the success handler from the first adapter or from within the wlCommonInit() method it does NOT throw the UNRESPONSIVE_HOST error."

Access denied in Message Queuing

I developed an application in Delphi 2010 that reads XML data from a transactional queue. It works fine if the queue is local or remote and I don't have to set permissions in both cases.
Now I have to convert that application into a Windows Service. I copied and pasted the same application into the service code, but when I try to read the queue I get the "Access denied" error. I'm doing the tests on my local machine.
Some people say that it's a matter of permissions. I found here in Stack Overflow some posts to the same problem but I didn't find the solution.
Any ideas? I'm using Windows 7 as well.
If you are running the application locally, you are running it under your Windows logon credentials. Services by default are launched under a different user account which may not have the same rights as your account does.
Bring up the service manager (start->services.msc), find your service in the list, right click it and select Properties. Then select the Log On tab and change it to a specific account name/password. (Use your account name / password.) You'll then be executing the code using the same credentials so your Access Denied error should go away.

Resources