Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

C#: Provide a code sample to show how to obtain g: ID device ticket using OnlineId API #29

Closed
maxgolov opened this issue Jun 18, 2019 · 7 comments
Labels
csharp C# layer issue documentation help wanted Extra attention is needed MRW Partner Team - Mixed Reality for Work wontfix This will not be worked on

Comments

@maxgolov
Copy link
Contributor

Our existing customers (MS Office, Edge) utilize OnlineId API to retrieve a global device ticket presentable to Collector++ service. That API allows to uniquely identify the global MSA Device Id, that a device gets assigned once during Windows installation.

Unfortunately there is no reference code example in SDK how to do that. Other customers are interested in enabling that flow and frequently asking for a customer sample.

@maxgolov maxgolov added documentation help wanted Extra attention is needed labels Jun 18, 2019
@maxgolov
Copy link
Contributor Author

Need to add sample for:

std::wstring serviceUrl = Mso::AB::Setting<std::wstring>(L"Microsoft.Office.Telemetry.MsaDeviceAuthServiceUrl", L"https://events.data.microsoft.com/OneCollector/1.0/");
std::wstring protocol = Mso::AB::Setting<std::wstring>(L"Microsoft.Office.Telemetry.MsaDeviceAuthPolicy", L"NFS_1wk_compact_SSL");
hr = onlineIdServiceTicketRequestFactory->CreateOnlineIdServiceTicketRequest(
    HStringReference(serviceUrl.c_str()).Get(),
    HStringReference(protocol.c_str()).Get(),
    &onlineIdServiceTicketRequest);

@maxgolov maxgolov added this to the Vibranium - 08.August milestone Jun 27, 2019
@maxgolov
Copy link
Contributor Author

Note that MRW team might be needing this example for UWP C# app as well.
It is not clear if we can rely on OnlineId service API from Universal Store app.

@maxgolov maxgolov added the MRW Partner Team - Mixed Reality for Work label Jul 10, 2019
@botrif
Copy link
Contributor

botrif commented Jul 23, 2019

While I'm finding the other APIs in C#, I can't find onlineIdServiceTicketRequestFactory. The ctor for OnlineIdServiceTicketRequest takes a service and policy string. Do you think I can simply use the above two strings directly?

@maxgolov
Copy link
Contributor Author

Please try passing this and let us know if you are getting the proper ticket value. One option is to try C++ SDK and compare if you get the same ticket using C# API you mentioned.

@maxgolov maxgolov added the csharp C# layer issue label Sep 10, 2019
@maxgolov maxgolov removed this from the Vibranium - 09.September milestone Sep 10, 2019
@maxgolov
Copy link
Contributor Author

@reyang - this ask is unique to C# customers using Direct Upload mode. At this time we do not have a documented / confirmed way of obtaining MSA User Id token from a C# app layer. This is not an issue for native C++ layer on Windows, specific only to C# layer. One suggestion is for the customer to explore what options are available, possibly for the customer to follow-up with ADAL team on that.

@maxgolov
Copy link
Contributor Author

maxgolov commented Jan 7, 2020

C# layer work not resourced for [Mn].

@maxgolov maxgolov changed the title Provide a code sample to show how to obtain g: ID device ticket using OnlineId API C#: Provide a code sample to show how to obtain g: ID device ticket using OnlineId API Jan 7, 2020
@maxgolov maxgolov added the wontfix This will not be worked on label Mar 5, 2020
@maxgolov
Copy link
Contributor Author

maxgolov commented Mar 5, 2020

Currently this C# SDK-related work is not resourced. Best course of action for someone needing to obtain MSA User ID ticket is to reach out to ADAL team or explore how the ticket acquisition is done in native code by Edge and Office teams. Closing this. Won't fix.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
csharp C# layer issue documentation help wanted Extra attention is needed MRW Partner Team - Mixed Reality for Work wontfix This will not be worked on
Projects
None yet
Development

No branches or pull requests

2 participants