github.com/linuxboot/fiano@v1.2.0/pkg/intel/metadata/cbnt/cbntkey/manifest_nocodegen.go (about) 1 // Copyright 2017-2021 the LinuxBoot Authors. All rights reserved 2 // Use of this source code is governed by a BSD-style 3 // license that can be found in the LICENSE file. 4 5 //go:build !manifestcodegen 6 // +build !manifestcodegen 7 8 // 9 // To avoid error "m.StructInfo.PrettyString undefined" we place this 10 // function to a file with a build tag "!manifestcodegen" 11 12 package cbntkey 13 14 import ( 15 "fmt" 16 17 "github.com/linuxboot/fiano/pkg/intel/metadata/common/pretty" 18 ) 19 20 // Print prints the Key Manifest. 21 func (m *Manifest) Print() { 22 if m.KeyAndSignature.Signature.DataTotalSize() < 1 { 23 fmt.Printf("%v\n", m.PrettyString(1, true, pretty.OptionOmitKeySignature(true))) 24 fmt.Printf(" --KeyAndSignature--\n\tKey Manifest not signed!\n\n") 25 } else { 26 fmt.Printf("%v\n", m.PrettyString(1, true, pretty.OptionOmitKeySignature(false))) 27 } 28 }