mirror of
				https://github.com/SSLMate/certspotter.git
				synced 2025-07-03 10:47:17 +02:00 
			
		
		
		
	Track log certificate expiry range
This commit is contained in:
		
							parent
							
								
									41ca1aaab8
								
							
						
					
					
						commit
						822a03f365
					
				
							
								
								
									
										15
									
								
								logs.go
									
									
									
									
									
								
							
							
						
						
									
										15
									
								
								logs.go
									
									
									
									
									
								
							@ -14,16 +14,19 @@ import (
 | 
			
		||||
	"crypto/sha256"
 | 
			
		||||
	"crypto/x509"
 | 
			
		||||
	"encoding/base64"
 | 
			
		||||
	"time"
 | 
			
		||||
)
 | 
			
		||||
 | 
			
		||||
type LogInfoFile struct {
 | 
			
		||||
	Logs []LogInfo `json:"logs"`
 | 
			
		||||
}
 | 
			
		||||
type LogInfo struct {
 | 
			
		||||
	Description string `json:"description"`
 | 
			
		||||
	Key         []byte `json:"key"`
 | 
			
		||||
	Url         string `json:"url"`
 | 
			
		||||
	MMD         int    `json:"maximum_merge_delay"`
 | 
			
		||||
	Description     string     `json:"description"`
 | 
			
		||||
	Key             []byte     `json:"key"`
 | 
			
		||||
	Url             string     `json:"url"`
 | 
			
		||||
	MMD             int        `json:"maximum_merge_delay"`
 | 
			
		||||
	CertExpiryBegin *time.Time `json:"cert_expiry_begin"`
 | 
			
		||||
	CertExpiryEnd   *time.Time `json:"cert_expiry_end"`
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
func (info *LogInfo) FullURI() string {
 | 
			
		||||
@ -152,3 +155,7 @@ func mustDecodeBase64(str string) []byte {
 | 
			
		||||
	}
 | 
			
		||||
	return bytes
 | 
			
		||||
}
 | 
			
		||||
func makeTime(seconds int64) *time.Time {
 | 
			
		||||
	t := time.Unix(seconds, 0)
 | 
			
		||||
	return &t
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user