mirror of
https://github.com/cloudflare/cloudflared.git
synced 2025-07-27 15:49:58 +00:00
AUTH-3221: Saves org token to disk and uses it to refresh the app token
This commit is contained in:
@@ -52,7 +52,7 @@ var mockRequest func(url, contentType string, body io.Reader) (*http.Response, e
|
||||
|
||||
// GenerateShortLivedCertificate generates and stores a keypair for short lived certs
|
||||
func GenerateShortLivedCertificate(appURL *url.URL, token string) error {
|
||||
fullName, err := cfpath.GenerateFilePathFromURL(appURL, keyName)
|
||||
fullName, err := cfpath.GenerateAppTokenFilePathFromURL(appURL, keyName)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
@@ -35,7 +35,7 @@ func TestCertGenSuccess(t *testing.T) {
|
||||
url, _ := url.Parse("https://cf-test-access.com/testpath")
|
||||
token := tokenGenerator()
|
||||
|
||||
fullName, err := cfpath.GenerateFilePathFromURL(url, keyName)
|
||||
fullName, err := cfpath.GenerateAppTokenFilePathFromURL(url, keyName)
|
||||
assert.NoError(t, err)
|
||||
|
||||
pubKeyName := fullName + ".pub"
|
||||
|
Reference in New Issue
Block a user