如何限制只有GSuit用户才能登录?

问题描述 投票:1回答:1

我使用的是 反应-谷歌-登录 我的react应用。以下是我的代码

    <GoogleLogin
    clientId="xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx.apps.googleusercontent.com"
    buttonText="Google"
    render={renderProps => (
    <button onClick={renderProps.onClick} className='google-login-button'>
    <img src={GoogleButton}/>
    </button>
    )}
    onSuccess={this.googleResponse}
    onFailure={() => console.log('error')}
/>

我想要的是,只有Gsuit的用户才能登录,就像Gmail的用户不能访问一样。

reactjs google-api google-login google-console-developer
1个回答
0
投票

如果还没有试过的话,可以用GoogleLogin的hostedDomain道具试一下。我发现这个相关的 限制访问谷歌登录. 或者你可以关注这个线程hai.Gsuit限制

© www.soinside.com 2019 - 2024. All rights reserved.