-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
NOISSUE - Add SANs option #27
Conversation
Signed-off-by: nyagamunene <[email protected]>
service.go
Outdated
net.ParseIP("192.168.100.4"), | ||
net.ParseIP("164.90.178.85"), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
make this dynamic
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Load both DNS names and IP addresses from the config, we can't have it hardcoded like this.
Signed-off-by: nyagamunene <[email protected]>
docker/config.yml
Outdated
organizational_unit: | ||
- "AbstractMachines_ca" | ||
country: | ||
- "Sirbea" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sirbea is not a country, and it should be France.
service.go
Outdated
config, err := LoadConfig(configFile) | ||
if err != nil { | ||
return &svc, err | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Load config in the main.go
and use it as a param in NewService
.
Signed-off-by: nyagamunene <[email protected]>
Signed-off-by: nyagamunene <[email protected]>
service.go
Outdated
@@ -756,3 +774,13 @@ func (s *service) loadCACerts(ctx context.Context) error { | |||
} | |||
return nil | |||
} | |||
|
|||
func parseIPs(ipStrings []string) []net.IP { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Extract config and config handling to a separate file. Make config IP list net.IP
instead of strings and parse during config creation.
Signed-off-by: nyagamunene <[email protected]>
docker/config.yml
Outdated
dns_names: | ||
- "localhost" | ||
ip_addresses: | ||
- "192.168.100.4" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- "192.168.100.4" | |
- "localhost" |
docker/config.yml
Outdated
- "localhost" | ||
ip_addresses: | ||
- "192.168.100.4" | ||
- "164.90.178.85" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
belongs to prism, don't set in this config, but rather create a config file on prism side
Signed-off-by: nyagamunene <[email protected]>
docker/config.yml
Outdated
province: | ||
- "Sirbea" | ||
locality: | ||
- "Sirbea" | ||
street_address: | ||
- "Sirbea" | ||
postal_code: | ||
- "Sirbea" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Signed-off-by: nyagamunene <[email protected]>
Signed-off-by: nyagamunene <[email protected]>
Signed-off-by: nyagamunene <[email protected]>
What type of PR is this?
This is a feature because it adds SANs option.
What does this do?
It adds SANs option for root and intermediate CA.
Which issue(s) does this PR fix/relate to?
N/A
Have you included tests for your changes?
N/A
Did you document any new/modified features?
N/A
Notes