Skip to content

Commit fa512d5

Browse files
chore: fix feature support to append user agent suffix (#4520)
* add feature to append user agent suffix * comment resolution
1 parent daf7e56 commit fa512d5

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

pkg/detectors/browserstack/browserstack.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ import (
1111
regexp "github.com/wasilibs/go-re2"
1212
"golang.org/x/net/publicsuffix"
1313

14+
"github.com/trufflesecurity/trufflehog/v3/pkg/common"
1415
"github.com/trufflesecurity/trufflehog/v3/pkg/detectors"
1516
"github.com/trufflesecurity/trufflehog/v3/pkg/pb/detectorspb"
1617
)
@@ -93,6 +94,8 @@ func verifyBrowserStackCredentials(ctx context.Context, client *http.Client, use
9394
return false, err
9495
}
9596
req.Header.Add("Content-Type", "application/json")
97+
req.Header.Add("User-Agent", common.UserAgent())
98+
9699
req.SetBasicAuth(username, accessKey)
97100

98101
res, err := client.Do(req)

0 commit comments

Comments
 (0)