none
Oauth and cross domain policy problem RRS feed

  • Question

  • I am new to Office app development and can't find answers to my questions, I hope that somebody could guide me to the right direction.



    I am trying to write an app for Outlook which should work on Outlook desktop and Web. The app firsts needs to authenticate on atlassian.net helpdesk services so it would be able to upload a selected email message as an attachment to the helpdesk service. I know the web service REST API, but I can't use it because of the domain policy restrictions.

    I know that I can't make any XMLrequests from javascript but I am not able to make a proxy page because I lack the ssl certificate for it.

    I was experimenting with Napa, but it seams you can write just plain html apps but that won't work for Oauth.

    I found an example http://blogs.msdn.com/b/officeapps/archive/2013/08/21/use-oauth-1-0-to-access-the-zotero-web-service-from-apps-for-office.aspx, but I am not sure how it really works.

    When you create an app on Napa, where does it host the files?

    How can I overcome the cross domain policy problem?




    Wednesday, November 25, 2015 12:22 PM

Answers

  • Hi,

    >>I found an example http://blogs.msdn.com/b/officeapps/archive/2013/08/21/use-oauth-1-0-to-access-the-zotero-web-service-from-apps-for-office.aspx, but I am not sure how it really works.<<

    The WCF service mentioned in this blog actually is an proxy. We will call the WCF service instead of real service. Here is an figure to illustrate it:

    You can get more detail about same-origin policy from link below:
    Addressing same-origin policy limitations in Office Add-ins

    >>When you create an app on Napa, where does it host the files?<<

    We are not able to host these files in NAPA. You can open any project in Visual Studio if you decide that you want to use features such as advanced debugging or use a web project as part of your Office Add-in.

    Regards & Fei


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.


    Thursday, November 26, 2015 2:54 AM
    Moderator

All replies

  • Ask Office Apps specific questions on the Developing Apps for Office 2013  forum instead.
    Wednesday, November 25, 2015 12:31 PM
  • I am new to Office app development and can't find answers to my questions, I hope that somebody could guide me to the right direction.



    I am trying to write an app for Outlook which should work on Outlook desktop and Web. The app firsts needs to authenticate on atlassian.net helpdesk services so it would be able to upload a selected email message as an attachment to the helpdesk service. I know the web service REST API, but I can't use it because of the domain policy restrictions.

    I know that I can't make any XMLrequests from javascript but I am not able to make a proxy page because I lack the ssl certificate for it.

    I was experimenting with Napa, but it seams you can write just plain html apps but that won't work for Oauth.

    I found an example http://blogs.msdn.com/b/officeapps/archive/2013/08/21/use-oauth-1-0-to-access-the-zotero-web-service-from-apps-for-office.aspx, but I am not sure how it really works.

    When you create an app on Napa, where does it host the files?

    How can I overcome the cross domain policy problem?

    CORS is not enabled on the web service and I can't change it.

    The web service won't support JSONP.

    Wednesday, November 25, 2015 12:35 PM
  • Hi,

    >>I found an example http://blogs.msdn.com/b/officeapps/archive/2013/08/21/use-oauth-1-0-to-access-the-zotero-web-service-from-apps-for-office.aspx, but I am not sure how it really works.<<

    The WCF service mentioned in this blog actually is an proxy. We will call the WCF service instead of real service. Here is an figure to illustrate it:

    You can get more detail about same-origin policy from link below:
    Addressing same-origin policy limitations in Office Add-ins

    >>When you create an app on Napa, where does it host the files?<<

    We are not able to host these files in NAPA. You can open any project in Visual Studio if you decide that you want to use features such as advanced debugging or use a web project as part of your Office Add-in.

    Regards & Fei


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.


    Thursday, November 26, 2015 2:54 AM
    Moderator