Skip to content

Commit 89c821a

Browse files
authored
secretservice: use the correct MIME content type (#2475)
Secret Service backends that validate MIME content types, such as oo7-daemon on Fedora 45, reject credential writes with 'Invalid content type: plain/text'. Authentication succeeds, but the credential is never stored and subsequent Git operations prompt again. Use the standard text/plain content type for secret values so these backends can store credentials. Existing credentials remain readable because lookups use the service and account attributes, and GCM reads the secret bytes without checking the content type. Only new or updated secrets get the corrected content type; no migration of existing entries is needed. Fixes #2473
2 parents 91d6da2 + 4549ca3 commit 89c821a

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎src/Core/Interop/Linux/SecretServiceCollection.cs‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ public class SecretServiceCollection : ICredentialStore
1616
private const string SchemaName = "com.microsoft.GitCredentialManager";
1717
private const string ServiceAttributeName = "service";
1818
private const string AccountAttributeName = "account";
19-
private const string PlainTextContentType = "plain/text";
19+
private const string PlainTextContentType = "text/plain";
2020

2121
private readonly string _namespace;
2222

0 commit comments

Comments
 (0)