Skip to content

Commit

Permalink
Merge pull request #10 from yahoo/sia
Browse files Browse the repository at this point in the history
Replace SIA Client references with SIA Provider
  • Loading branch information
havetisyan authored Jan 23, 2017
2 parents 4f6b237 + 4da69f7 commit 4063b5b
Show file tree
Hide file tree
Showing 27 changed files with 488 additions and 1,876 deletions.
2 changes: 0 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ utils/zms_cli/pkg/
utils/zms_cli/src/
utils/athenz_conf/pkg/
utils/athenz_conf/src/
clients/java/sia/src/test/resources/svc.ntoken
clients/java/zpe/src/test/resources/upd_pol_dir/
ui/build/
ui/node_modules/
Expand All @@ -28,7 +27,6 @@ utils/zpe_policy_updater/src/test/resources/sys.auth.new.pol
clients/java/zpe/src/test/resources/pol_dir/angler.pol
clients/java/zpe/src/test/resources/pol_dir/empty.pol
clients/java/zpe/src/test/resources/pol_dir/sports.pol
clients/java/sia/bin/
clients/java/zms/bin/
clients/java/zpe/bin/
clients/java/zts/bin/
Expand Down
14 changes: 7 additions & 7 deletions clients/go/zms/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ func (client ZMSClient) httpGet(url string, headers map[string]string) (*http.Re
return nil, err
}
client.addAuthHeader(req)
if headers != nil {
if headers != nil {
for k, v := range headers {
req.Header.Add(k, v)
}
Expand All @@ -87,7 +87,7 @@ func (client ZMSClient) httpDelete(url string, headers map[string]string) (*http
return nil, err
}
client.addAuthHeader(req)
if headers != nil {
if headers != nil {
for k, v := range headers {
req.Header.Add(k, v)
}
Expand All @@ -107,7 +107,7 @@ func (client ZMSClient) httpPut(url string, headers map[string]string, body []by
}
req.Header.Add("Content-type", "application/json")
client.addAuthHeader(req)
if headers != nil {
if headers != nil {
for k, v := range headers {
req.Header.Add(k, v)
}
Expand All @@ -127,7 +127,7 @@ func (client ZMSClient) httpPost(url string, headers map[string]string, body []b
}
req.Header.Add("Content-type", "application/json")
client.addAuthHeader(req)
if headers != nil {
if headers != nil {
for k, v := range headers {
req.Header.Add(k, v)
}
Expand All @@ -147,7 +147,7 @@ func (client ZMSClient) httpPatch(url string, headers map[string]string, body []
}
req.Header.Add("Content-type", "application/json")
client.addAuthHeader(req)
if headers != nil {
if headers != nil {
for k, v := range headers {
req.Header.Add(k, v)
}
Expand All @@ -169,7 +169,7 @@ func (client ZMSClient) httpOptions(url string, headers map[string]string, body
req.Header.Add("Content-type", "application/json")
}
client.addAuthHeader(req)
if headers != nil {
if headers != nil {
for k, v := range headers {
req.Header.Add(k, v)
}
Expand Down Expand Up @@ -2123,7 +2123,7 @@ func (client ZMSClient) GetAccess(action ActionName, resource YRN, domain Domain
}
}

func (client ZMSClient) Getaccessext(action ActionName, resource string, domain DomainName, checkPrincipal EntityName) (*Access, error) {
func (client ZMSClient) GetAccessExt(action ActionName, resource string, domain DomainName, checkPrincipal EntityName) (*Access, error) {
var data *Access
url := client.URL + "/access/" + fmt.Sprint(action) + encodeParams(encodeStringParam("resource", string(resource), ""), encodeStringParam("domain", string(domain), ""), encodeStringParam("principal", string(checkPrincipal), ""))
resp, err := client.httpGet(url, nil)
Expand Down
12 changes: 6 additions & 6 deletions clients/go/zts/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ func (client ZTSClient) httpGet(url string, headers map[string]string) (*http.Re
return nil, err
}
client.addAuthHeader(req)
if headers != nil {
if headers != nil {
for k, v := range headers {
req.Header.Add(k, v)
}
Expand All @@ -87,7 +87,7 @@ func (client ZTSClient) httpDelete(url string, headers map[string]string) (*http
return nil, err
}
client.addAuthHeader(req)
if headers != nil {
if headers != nil {
for k, v := range headers {
req.Header.Add(k, v)
}
Expand All @@ -107,7 +107,7 @@ func (client ZTSClient) httpPut(url string, headers map[string]string, body []by
}
req.Header.Add("Content-type", "application/json")
client.addAuthHeader(req)
if headers != nil {
if headers != nil {
for k, v := range headers {
req.Header.Add(k, v)
}
Expand All @@ -127,7 +127,7 @@ func (client ZTSClient) httpPost(url string, headers map[string]string, body []b
}
req.Header.Add("Content-type", "application/json")
client.addAuthHeader(req)
if headers != nil {
if headers != nil {
for k, v := range headers {
req.Header.Add(k, v)
}
Expand All @@ -147,7 +147,7 @@ func (client ZTSClient) httpPatch(url string, headers map[string]string, body []
}
req.Header.Add("Content-type", "application/json")
client.addAuthHeader(req)
if headers != nil {
if headers != nil {
for k, v := range headers {
req.Header.Add(k, v)
}
Expand All @@ -169,7 +169,7 @@ func (client ZTSClient) httpOptions(url string, headers map[string]string, body
req.Header.Add("Content-type", "application/json")
}
client.addAuthHeader(req)
if headers != nil {
if headers != nil {
for k, v := range headers {
req.Header.Add(k, v)
}
Expand Down
27 changes: 0 additions & 27 deletions clients/java/sia/README.md

This file was deleted.

69 changes: 0 additions & 69 deletions clients/java/sia/pom.xml

This file was deleted.

47 changes: 0 additions & 47 deletions clients/java/sia/src/main/java/com/yahoo/athenz/sia/SIA.java

This file was deleted.

Loading

0 comments on commit 4063b5b

Please sign in to comment.