working commit

This commit is contained in:
2026-02-26 18:15:10 +02:00
commit 19b173357a
9 changed files with 328 additions and 0 deletions

32
client.go Normal file
View File

@@ -0,0 +1,32 @@
package client
import (
"crypto/tls"
"net/http"
)
type Client struct {
httpClient *http.Client
authenticator Authenticator
userAgent string
}
func NewClient(skipTLSVerify bool) *Client {
transport := &http.Transport{
TLSClientConfig: &tls.Config{
InsecureSkipVerify: skipTLSVerify,
},
}
httpClient := &http.Client{
Transport: transport,
}
return &Client{
httpClient: httpClient,
userAgent: "ociClient/1.0",
}
}
func (cli *Client) SetAuthenticator(auth Authenticator) {
cli.authenticator = auth
}