Skip to content
Snippets Groups Projects
Commit c9888aa6 authored by Davide Vaghetti's avatar Davide Vaghetti
Browse files

Added simple script to parse the security contacts of the eduGAIN identity federations

parent b64f09b4
Branches
No related tags found
No related merge requests found
#!/usr/bin/env python3
# This script consume the eduGAIN API to retrieve the details of all the
# eduGAIN identity federations and parse it to create a list of
# security email addresses, if available, and the corresponding
# federation name in CSV format.
# This list will be printed to stdout.
import requests
feds = requests.get('https://technical.edugain.org/api.php?action=list_feds_full')
feds_dict = feds.json()
for fed in feds_dict:
if 'security_contact' in feds_dict[fed]:
if 'mail' in feds_dict[fed]['security_contact']:
print(f"{fed},{feds_dict[fed]['security_contact']['mail']['value']}")
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment