mirror of
https://github.com/gocsaf/csaf.git
synced 2025-12-22 18:15:42 +01:00
Fixed TLP model conversion. Fixed wrong .well-known path
This commit is contained in:
parent
048c0dce89
commit
e5a6a8e2da
2 changed files with 3 additions and 3 deletions
|
|
@ -63,10 +63,10 @@ func (cfg *config) GetOpenPGPURL(key string) string {
|
||||||
}
|
}
|
||||||
|
|
||||||
func (cfg *config) modelTLPs() []csaf.TLPLabel {
|
func (cfg *config) modelTLPs() []csaf.TLPLabel {
|
||||||
tlps := make([]csaf.TLPLabel, len(cfg.TLPs))
|
tlps := make([]csaf.TLPLabel, 0, len(cfg.TLPs))
|
||||||
for _, t := range cfg.TLPs {
|
for _, t := range cfg.TLPs {
|
||||||
if t != tlpCSAF {
|
if t != tlpCSAF {
|
||||||
tlps = append(tlps, csaf.TLPLabel(t))
|
tlps = append(tlps, csaf.TLPLabel(strings.ToUpper(string(t))))
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return tlps
|
return tlps
|
||||||
|
|
|
||||||
|
|
@ -389,7 +389,7 @@ func NewProviderMetadata(canonicalURL string) *ProviderMetadata {
|
||||||
func NewProviderMetadataDomain(domain string, tlps []TLPLabel) *ProviderMetadata {
|
func NewProviderMetadataDomain(domain string, tlps []TLPLabel) *ProviderMetadata {
|
||||||
|
|
||||||
pm := NewProviderMetadata(
|
pm := NewProviderMetadata(
|
||||||
domain + "/.wellknown/csaf/provider-metadata.json")
|
domain + "/.well-known/csaf/provider-metadata.json")
|
||||||
|
|
||||||
if len(tlps) == 0 {
|
if len(tlps) == 0 {
|
||||||
return pm
|
return pm
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue