mirror of
https://github.com/microsoft/onefuzz.git
synced 2025-06-10 17:21:34 +00:00
Fixing bug in registration.py for creating CLI SP's. (#2828)
* Fixing bug in registration.py for creating CLI SP's. * Formatting.
This commit is contained in:
parent
85fe434b3e
commit
0bc22a8073
@ -244,7 +244,6 @@ def create_application_registration(
|
||||
app = get_application(
|
||||
display_name=onefuzz_instance_name, subscription_id=subscription_id
|
||||
)
|
||||
|
||||
if not app:
|
||||
raise Exception("onefuzz app registration not found")
|
||||
|
||||
@ -338,7 +337,9 @@ def create_application_registration(
|
||||
registered_app_id = registered_app["appId"]
|
||||
app_id = app["appId"]
|
||||
|
||||
authorize_and_assign_role(app_id, registered_app_id, approle, subscription_id)
|
||||
authorize_and_assign_role(
|
||||
UUID(app_id), UUID(registered_app_id), approle, subscription_id
|
||||
)
|
||||
return registered_app
|
||||
|
||||
|
||||
@ -434,7 +435,6 @@ def get_application(
|
||||
filters.append("displayName eq '%s'" % display_name)
|
||||
|
||||
filter_str = " and ".join(filters)
|
||||
|
||||
apps = query_microsoft_graph(
|
||||
method="GET",
|
||||
resource="applications",
|
||||
|
Loading…
x
Reference in New Issue
Block a user