github.com/opentelekomcloud/gophertelekomcloud@v0.9.3/openstack/identity/v3.0/security/ListLoginProtectionConfiguration.go (about) 1 package security 2 3 import ( 4 golangsdk "github.com/opentelekomcloud/gophertelekomcloud" 5 "github.com/opentelekomcloud/gophertelekomcloud/internal/extract" 6 ) 7 8 func ListLoginProtectionConfigurations(client *golangsdk.ServiceClient) ([]LoginProtectionConfig, error) { 9 // GET /v3.0/OS-USER/login-protects 10 raw, err := client.Get(client.ServiceURL("OS-USER", "login-protects"), nil, nil) 11 if err != nil { 12 return nil, err 13 } 14 15 var res []LoginProtectionConfig 16 err = extract.IntoSlicePtr(raw.Body, &res, "login_protects") 17 return res, err 18 }