Windows Phone 8.1 user ID - runtime

I have a problem with getting User ID but I mean programmatically. Is any chance to get User's Live ID or something like that ? Because I want use trial experience with expiration time but is only one way how to do this. Storing all user's ID's and after installation check their identity. I don't want to use advertisement ID because it is not working in every case. Not every user is using this kind of ID.
So any ideas ?

You won't get any personal information without asking the user.
But the windows store features a trial mode with expiration. Check out the topic on MSDN.
Otherwise there is an overview on Idendity on Windows and you can use WebAuthenticationBroker on the Phone.

Related

Is there a way to change a Google Account name/email?

I have ran into a problematic situation, which I really hope I can get help with.
I'm working on Jive Software solutions and we have a product that integrates Google Drive and Gmail.
This integration product was once part of a startup that was acquired by Jive and as such, the Google api project we are using for the integration belongs to a Google Account of a specific person which no longer works in Jive (we do have the credentials for the account though).
The problem is, that we want this account to be ours, i.e, a Jive software one.
So, one option I have, is to create a new account and replace the api account I'm using in the code to use the new one. This is bad, as it will break all the current authenticated clients, and will force them to take the oauth process all over again.
The other option I see, is to convert the existing Google account we are using to a jivesoftware one, so it will not be associated to any specific person but it will still be the same account.
Specifically I'm interesting in changing the Name and Email of this account.
Any suggestions of how we can achieve that?
A third option could be moving the api project to owned by another google account, but I couldn't find such an option in the UI, any clue?
There is no way to change a gmail address. You can forward all email to a new address with the name and email address you would like though.
This way you access all the email from an account that is a Jive software one but it is being forwarded from the old one still. However no one directly accesses the old one.
Check out https://support.google.com/mail/answer/10957?hl=en for more info.
According to the documentation, if you use Gmail with your Google Account, it's not currently possible to change your Gmail username after you've registered. with your username being the full email address you used to create your account. You can, however, change your nick name by going to https://myaccount.google.com and clicking Personal Info.

how to invalidate another session in worklight

Customer want to restrict duplicate login for the App, once user login from another phone, the session of previous phone should be invalidated.
but I can't find the API for worklight to do this, besides using push, another suggestions? thank you very much.
Worklight indeed does not provide any API for this type of scenario.
Here is what I am thinking as an example of what can be done:
Device #1 is an Asus, device #2 is an LG
As the user log-ins, you will store the device information in the Worklight database (using WL.Client.setUserPref)
When the user will try to log-in again from another device, you could pull the existing pref (using WL.Client.getUserPref) and compare the device types
If they are not the same, logout current userId and re-login
(Consult the user documentation for additional API methods around userpref)
This could be a way to ensure the user is logged only from one device.
You could also use the userId associated with the deviceId and update upon every login if (currentDeviceId != latestDeviceId) logout(); and so on...
Here I have posted a implementation mechanism which strikes in my mind.
Its still a suggestion.
Whenever a user tries to login an entry can be made in backend[DB/Webserice] which tells about the user/device information.
If the user info is existing already then you can prompt a dialog box to the user The account has been logged in already, if you continue to login the previous session would be logged out trigger a push notification to the previously logged in user device, if user continues.
Now a notification will be reached to previously logged in device. Here you can implement the logic to execute the WL.Client.logout(realm, options).
It would be great if someone post answer better than what I did.
And also let me know if my suggestion was helpful or not.

How To Add A Secure Login To My C# Application?

I have a C# desktop app where a user enters his company ID card number as a simple form of "authentication" against a database table of valid employees. If the user is found in the table with the correct permission level, the app runs and the user can use all of the screens and menus in the application. Problem is anyone who has a valid user's ID number (perhaps from a lost or stolen ID card) can run the program and get to the data.
We want to make this application more secure. Is there a way to use the Windows ID and pwd to authenticate application users? At the very least we would like to force app users to re-enter the credentials (ID and pwd) of the currently logged in Windows user on the machine. If that fails to authenticate then the application quits and will not run.
What are my options for adding this "feature" to my app? What is the easiest way to do it? LDAP bind? Compare the Windows ID entered to the User ID found in LDAP? What is the most secure way to do it? I"m good with making my apps talk to the database, but I've never done much with Windows security or authentication, so you'll have to talk down at my level. We want to avoid storing Windows user ID's in the database. The app is a VS 2008 project, but I will someday need to do the same thing in my VS 2010 projects. Thanks!

Windows Phone 7 UserExtenedProperties opinion…

I was thinking of a way to some how connect my phone user base to my site user base. Right now if an item gets added to the site via the phone the userId is generic and the site displays it as SmartPhoneUser. I was thinking it might be cool to display the unique phone id by using the UserExtenedProperties, however, after reading Nick Harris's blog about it I'm thinking it may not be a good idea as I don't want users to think I'm up to anything nefarious.
So I'm wondering if there are any suggestions out there on how to accomplish this task. Right now my site uses the JanRain module that allows multiple logins from other sites (Facebook, Yahoo, Google etc.). I'm letting users log in to their own accounts and using the information from those sites to populate my user table. I'm not sure if WP7 has something similar I can use.
Any thoughts on how I can accomplish what I want to do without using the ExtendedProperties?
We can accomplish something similar by creating a unique guid/DateTimeStamp KEY the first time the app launches and stored it in Isolated storage.
Reusing the same KEY by reading it from Isolated Storage should work.
[N.B. : Anybody with other ideas please do suggest/comment/contribute. Tx.]

Is UserExtendedProperties.GetValue user-specific or device-specific?

I'd like to use UserExtendedProperties.GetValue to associate a user with a high score table in a game I'm working on. Reading Microsoft's own API description I cannot work out whether this applies to a user (blah#live.com) or a physical device. Does anyone know?
Chris
UserExtendedProperties.GetValue("ANID") is an anonymous ID based on the user's Live ID. So, the same Live ID logged in from multiple WP7 devices will have the same ANID.

Resources