If you want to do it the ‘right’ way, then you should delve into OnlineSubsystem functionality and especially OnlineIdentity interface. It’s not a particularly easy task.
If you want a cheap&dirty way then you can just hook into GameMode’s or GameSession’s Login() methods and add your checks there. This can involve sending a HTTP request to your web-service to check with an account database for a match or anything else you might want.