GBear Posted December 16, 2016 Share Posted December 16, 2016 i'm developing All platform MMORPG.. i wanna use guest id to login. and i wanna get same id if login by same machine. how can i generate guestid in html5 thx a lots.. Quote Link to comment Share on other sites More sharing options...
mattstyles Posted December 16, 2016 Share Posted December 16, 2016 Not exactly sure what you're after, you want something unique that connects a user with a specific machine? Not sure there's a sure-fire accurate way to do that, but you could simply stuff the id into local storage and use that from the same machine (well, same browser), there shouldn't be any security implications of doing so (if there are you may be doing something slightly odd with the ids or I've overlooked something). This would not solve omni-channel logins, but thats not something a guest should be able to do anyway. Quote Link to comment Share on other sites More sharing options...
GBear Posted December 16, 2016 Author Share Posted December 16, 2016 @mattstyles hi matt~~~ thx answer... i'm thinking about how user login easily. so pc platform is using login system that login by id and password but i think this is not easy. so if user can generate unique id, user can login directly and in this case there are some condition - same machine get same unique id thx... Quote Link to comment Share on other sites More sharing options...
mattstyles Posted December 16, 2016 Share Posted December 16, 2016 You could key token against IP, you'll get that, it's hardly foolproof though, you'd have to test it thoroughly, and doesn't account for cases where the ip changes, such as logins from mobile phones for example. Given that browsers can remember login details, including passwords, is it really that big of an issue? Most of the time I have my passwords saved both in a password manager (mainly for omni-channel) and in the browser so I visit a url and it auto-populates the fields, logging me in, or, logs me in via cookies stored locally (some may even do some other stuff). I'm not sure what benefits trying to create a new method introduces. Quote Link to comment Share on other sites More sharing options...
GBear Posted December 22, 2016 Author Share Posted December 22, 2016 @mattstyles hi mat.. i don't know correct.. i'm thinking how can login easy on pc like mobile games's app.. mobile games is logined automatically or automatically authorized many channel like google or appstore(ios) or ...something else... if it have not. .it login automatically by guest id.. so i'm thinking how user can login more easy first..like mobile's guest id. but i can't think how can make unique guest id ( easy to make uniqueId but if i don't know after re-login) thx mattstyles.. Quote Link to comment Share on other sites More sharing options...
mattstyles Posted December 22, 2016 Share Posted December 22, 2016 I'm not sure I'm getting it. When I download a mobile app (lets say one of the big boys like Twitter or Facebook) I still have to login with my login credentials, simply to associate this login with my actual account, after that the app can remember those details use them to login next time without my intervention. You can do this on the web via local storage methods, whether you consider those secure enough for your purposes is up to you. There is no magic login associated with the device, and even if there was how would the service associate that device with the actual account? It can't, without human intervention, which isn't a problem if its a one-off, once you've done the human bit and created an association between a login and an account then you can do the automatic bit for subsequent app loads. Just a note that, which I think you've already got a handle on, store tokens, not login details. Quote Link to comment Share on other sites More sharing options...
labrat.mobi Posted January 15, 2017 Share Posted January 15, 2017 Can't you generate uniqueId on server side? When user first time opens the game, you can check for uniqueId in local storage. If Id is not found, then send a request server asking for uniqueID. Then save that uniqueId back to user's browser. Problem is if player uses different browser, he/she will be treated as new user. I would recommend you to look in Google's firebase authentication - they support login via facebook, twitter, google plus, github, etc.. also they have some kinda of guest authentication. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.