Categorygithub.com/nokute78/pe-cert-reader
repository
0.0.1
Repository: https://github.com/nokute78/pe-cert-reader.git
Documentation: pkg.go.dev

# Packages

No description provided by the author
No description provided by the author

# README

pe-cert-reader

Go Report Card GoDoc

A library and tool to read certs of PE file.

Command

$ ./pe-cert-reader -h
Usage of pe-cert-reader:
  -V	show Version
  -d	dump certs

-d option dump cert(s) from PE file. The suffix of cert file is .certX.

Example

package main

import (
	"flag"
	"fmt"
	"github.com/nokute78/pe-cert-reader/pkg/pecert"
)

func main() {
	flag.Parse()
	for _, file := range flag.Args() {
		attrs, err := pecert.GetAttributeCertificatesFromPath(file)
		if err != nil {
			fmt.Printf("%s\n", err)
		}
		for i, attr := range attrs {
			fmt.Printf("%d: %v\n",i, attr)
		}
	}
}

Reference

PE Format Specification

License

Apache License v2.0