Skip to content

Commit

Permalink
update organization => farmerorganization
Browse files Browse the repository at this point in the history
  • Loading branch information
taigrr committed Nov 4, 2023
1 parent b823b5f commit 951e1f7
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions certs/tls.go
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ func genCACert() {
caCert := x509.Certificate{
SerialNumber: serialNumber,
Subject: pkix.Name{
Organization: config.Organization,
Organization: []string{config.FarmerOrganization},
},
NotBefore: notBefore,
NotAfter: notBefore.Add(config.CertificateValidTime),
Expand Down Expand Up @@ -175,7 +175,7 @@ func GenCert() {
template := x509.Certificate{
SerialNumber: serialNumber,
Subject: pkix.Name{
Organization: config.Organization,
Organization: []string{config.FarmerOrganization},
},
NotBefore: notBefore,
NotAfter: notBefore.Add(config.CertificateValidTime),
Expand Down
6 changes: 3 additions & 3 deletions config/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ var (
NKeyFarmerPubFile string
NKeySproutPrivFile string
NKeySproutPubFile string
Organization []string
FarmerOrganization string
RootCA string
RootCAPriv string
SproutID string
Expand Down Expand Up @@ -122,7 +122,7 @@ func LoadConfig(binary string) {
jety.SetDefault("nkeyfarmerprivfile", "/etc/grlx/pki/farmer/farmer.nkey")
jety.SetDefault("rootca", "/etc/grlx/pki/farmer/tls-rootca.pem")
jety.SetDefault("rootcapriv", "/etc/grlx/pki/farmer/tls-rootca-key.pem")
jety.SetDefault("organization", "GRLX Development")
jety.SetDefault("organization", "grlx farmer")
jety.SetDefault("farmerbusinterface", jety.GetString("farmerinterface"))
CertHosts = jety.GetStringSlice("certhosts")
AdminPubKeys := jety.GetStringMap("pubkeys")
Expand Down Expand Up @@ -205,7 +205,7 @@ func LoadConfig(binary string) {
NKeyFarmerPubFile = jety.GetString("nkeyfarmerpubfile")
NKeySproutPrivFile = jety.GetString("nkeysproutprivfile")
NKeySproutPubFile = jety.GetString("nkeysproutpubfile")
Organization = jety.GetStringSlice("organization")
FarmerOrganization = jety.GetString("farmerorganization")
RootCA = jety.GetString("rootca")
RootCAPriv = jety.GetString("rootcapriv")
SproutID = jety.GetString("sproutid")
Expand Down

0 comments on commit 951e1f7

Please sign in to comment.