mirror of
https://github.com/GAM-team/GAM.git
synced 2026-06-04 06:11:39 +00:00
Compare commits
5 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
b5580c5649 | ||
|
|
e9200ea8fb | ||
|
|
2e0c280ea6 | ||
|
|
3948a414b5 | ||
|
|
2c83068605 |
@@ -777,8 +777,9 @@ def checkConnection():
|
||||
success_count = 0
|
||||
for host in hosts:
|
||||
try_count += 1
|
||||
check_line = f'Checking {host} ({try_count}/{host_count})...'
|
||||
sys.stdout.write(f'{check_line:<60}')
|
||||
ip = socket.gethostbyname(host)
|
||||
check_line = f'Checking {host} ({ip}) ({try_count}/{host_count})...'
|
||||
sys.stdout.write(f'{check_line:<80}')
|
||||
sys.stdout.flush()
|
||||
try:
|
||||
httpc.request(f'https://{host}/', 'HEAD', headers=headers)
|
||||
@@ -10593,7 +10594,6 @@ OAUTH2_SCOPES = [
|
||||
'name': 'Cloud Identity - User Invitations',
|
||||
'subscopes': ['readonly'],
|
||||
'scopes': 'https://www.googleapis.com/auth/cloud-identity.userinvitations',
|
||||
'offByDefault': True,
|
||||
},
|
||||
{
|
||||
'name': 'Contact Delegation',
|
||||
|
||||
@@ -637,8 +637,8 @@ class _ShortURLFlow(google_auth_oauthlib.flow.InstalledAppFlow):
|
||||
code = parsed_params.get('code', [None])[0]
|
||||
try:
|
||||
fetch_args = {'code': code}
|
||||
if GC_Values.get('GC_CA_FILE'):
|
||||
fetch_args['verify'] = GC_Values.get('GC_CA_FILE')
|
||||
if GC_Values.get(GC_CA_FILE):
|
||||
fetch_args['verify'] = GC_Values.get(GC_CA_FILE)
|
||||
self.fetch_token(**fetch_args)
|
||||
break
|
||||
except Exception as e:
|
||||
|
||||
@@ -25,7 +25,7 @@ def _reduce_name(name):
|
||||
|
||||
def is_invitable_user(email):
|
||||
'''return email isInvitableUser'''
|
||||
svc = gapi_cloudidentity.build_dwd('cloudidentity')
|
||||
svc = gapi_cloudidentity.build('cloudidentity')
|
||||
customer = _get_customerid()
|
||||
encoded_email = quote_plus(email)
|
||||
name = f'{customer}/userinvitations/{encoded_email}'
|
||||
@@ -35,7 +35,7 @@ def is_invitable_user(email):
|
||||
|
||||
def _generic_action(action):
|
||||
'''generic function to call actionable APIs'''
|
||||
svc = gapi_cloudidentity.build_dwd('cloudidentity')
|
||||
svc = gapi_cloudidentity.build('cloudidentity')
|
||||
customer = _get_customerid()
|
||||
email = sys.argv[3].lower()
|
||||
encoded_email = quote_plus(email)
|
||||
@@ -55,7 +55,7 @@ def _generic_action(action):
|
||||
|
||||
def _generic_get(get_type):
|
||||
'''generic function to call read data APIs'''
|
||||
svc = gapi_cloudidentity.build_dwd('cloudidentity')
|
||||
svc = gapi_cloudidentity.build('cloudidentity')
|
||||
customer = _get_customerid()
|
||||
email = sys.argv[3].lower()
|
||||
encoded_email = quote_plus(email)
|
||||
@@ -75,7 +75,7 @@ def bulk_is_invitable(emails):
|
||||
if response.get('isInvitableUser'):
|
||||
rows.append({'invitableUsers': request_id})
|
||||
|
||||
svc = gapi_cloudidentity.build_dwd('cloudidentity')
|
||||
svc = gapi_cloudidentity.build('cloudidentity')
|
||||
customer = _get_customerid()
|
||||
todrive = False
|
||||
#batch_size = 1000
|
||||
@@ -139,7 +139,7 @@ USERINVITATION_STATE_CHOICES_MAP = {
|
||||
|
||||
def print_():
|
||||
'''gam print userinvitations'''
|
||||
svc = gapi_cloudidentity.build_dwd('cloudidentity')
|
||||
svc = gapi_cloudidentity.build('cloudidentity')
|
||||
customer = _get_customerid()
|
||||
todrive = False
|
||||
titles = ['name', 'state', 'updateTime']
|
||||
|
||||
@@ -8,7 +8,7 @@ import platform
|
||||
import re
|
||||
|
||||
GAM_AUTHOR = 'Jay Lee <jay0lee@gmail.com>'
|
||||
GAM_VERSION = '6.23'
|
||||
GAM_VERSION = '6.24'
|
||||
GAM_LICENSE = 'Apache License 2.0 (http://www.apache.org/licenses/LICENSE-2.0)'
|
||||
|
||||
GAM_URL = 'https://jaylee.us/gam'
|
||||
|
||||
Reference in New Issue
Block a user