Comments (9)
Reassigning to @davidchesnut because this is an auth sample request.
from office-add-in-samples.
Hi, ideally, an add-in that runs within OWA (Outlook web app), that pushes a dialog whereby an external website is used for auth and, if successful, redirects to the add-in taskpane.
from office-add-in-samples.
@davidchesnut OK to close this issue yet?
from office-add-in-samples.
Hi @elthombre I apologize for not getting this answer posted sooner. I thought I had posted awhile back, but I dont see it here, so I must have missed this somehow.
The dialog is based on an archived sample here: https://github.com/OfficeDev/Office-Add-in-Auth0 If you reuse the code just be sure it is up-to-date with latest library versions and security recommendations. We're moving away from these sorts of samples that are more about non-Office technologies such as Auth0 or MSAL which already have their own documentation. For example, MSAL and Microsoft identity have a ton of samples across multiple platforms and scenarios. It makes more sense to reuse those samples, rather than reinvent them all in an Office context. Separate from this issue, the team is working on providing guidance on how you can take those samples and adopt them to Office (through the dialog API).
Hope this helps!
David
from office-add-in-samples.
@davidchesnut , the problem with those recommendations is that under the circumstances those examples represent, the developer has complete control of the entire application, right? The application is built from scratch and those samples provide guidance for sign-on.
As an Office developer, we do not have control of the pre-existing environment. Meanwhile, the demands placed upon us are to extend and to customize. Sign-on is only one aspect.
from office-add-in-samples.
Hi @elthombre, to be clear, when you mention the "pre-existing environment" are you referring to the M365 tenant where your add-in is deployed? As long as the admin consents your add-in should work correctly with the users on that tenant. Most of our guidance is built around using the on-behalf-of (OBO) flow. So I would recommend starting with the samples that indicate they use OBO. For example, Call Microsoft Graph via OBO.
from office-add-in-samples.
@davidchesnut , no, what I am saying is that these samples related to authentication are segregated from the solution in question. If I'm building a web app or mobile app or desktop app from scratch, etc., I can control the entire experience and have access to the entire project. In MS Office development, one is working within a pre-existing environment where limited aspects may be exposed.
from office-add-in-samples.
Ok, so referring to the sandboxed environment of the task pane running in a webview (desktop) or iFrame (online)? That is true that unlike VSTO solutions you'll be more constrained to just working with the Office.js APIs (or browser features.) Auth will continue to work, and you can use SSO so you don't have to sign in the user twice. Is there a specific challenge you are running into with building an Office Add-in?
from office-add-in-samples.
@davidchesnut - my apologies here, I've been working on something new related to Teams. This thread was originally created over a year-and-a-half ago. What I presently face is different but I will add that the demands of the client at the time of the original post created some constraints that did not align with Microsoft's recommendations / best practices.
from office-add-in-samples.
Related Issues (20)
- Blazor excel Addin sample: history.pushState is not a function HOT 6
- Having trouble getting started HOT 25
- .NET7.0 not compatible ascendant with .NET6.0 for BlazorAddin HOT 4
- Build Solution make disappear ribbon buttons in BlazorAddin HOT 4
- Making a TS BlazorAddin HOT 12
- Having issue while running the sample HOT 3
- WARNING in entrypoint size limit HOT 5
- Deploying event-driven sample to a server HOT 1
- Outlook on Windows - OnAppointmentSend Handler of OfficeJS - not working for API calls HOT 3
- Outlook on window How to embed into WPF projects? HOT 1
- VersionOverrides link is broken in samples HOT 3
- Getting the text to the cursor position HOT 2
- DotNet.createJSObjectReference() TS Type HOT 3
- Debugging Blazor Addin project HOT 11
- DotNet.invokeMethodAsync function disabled with .NET 7 RC2 and 8 p5 in a Blazor addin project HOT 3
- Office-Add-in-Microsoft-Graph-React - production redirectUri HOT 2
- what are the exact prerequesites to install/side-load an Outlook add-in? HOT 19
- .NET7.0 rc2 threads disable WASM Blazor HOT 2
- Missing c# breack points HOT 5
- Tutorial for excel insert file doesn't work HOT 6
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from office-add-in-samples.