Use ssh_service.public_addrs in IsMFARequired check#24070
Conversation
3910c09 to
76be347
Compare
russjones
left a comment
There was a problem hiding this comment.
Looks like you are changing how a node will be represented in the backend. Did you do any testing to make sure our version compatibility is not broken.
Yes, I started with Auth+Node v12 and then upgraded Auth then Node to this branch. |
ec45cee to
2db1480
Compare
|
I'm converting this to draft until #24250 is merged. |
ad14764 to
afe00a3
Compare
There was a problem hiding this comment.
Is this still needed? Should all callers be using GetPublicAddrs which will fallback to just returning the PublicAddr if PublicAddrs are not set?
There was a problem hiding this comment.
Now this is just a helper function to return the first addr or empty string so we don't need to do the following for every caller:
var addr string
if addrs := s.GetPublicAddrs(); len(addrs) != 0 {
adrr = s.Spec.PublicAddrs[0]
}There was a problem hiding this comment.
Are two servers equivalent if they have the same public addresses but in a different order?
There was a problem hiding this comment.
I think it is safe to say no, I'm not aware of any reason why the public addresses would be scrambled unless the node config was changed.
There was a problem hiding this comment.
Should we add GetPublicAddrs?
There was a problem hiding this comment.
It's not needed right now, so no for now.
5ac6ce9 to
eb96513
Compare
eb96513 to
caf0572
Compare
…f discarding them * Use Server.PublicAddrs when checking if session MFA is required * Deprecate server PublicAddr in favor of PublicAddrs
caf0572 to
ed903d1
Compare
Changes:
Server.PublicAddrsto savessh_service.public_addrs(previously discarded after the connection to auth was made).Server.PublicAddrswhen looking for a node-based match for per session MFA.Server.ProxyAddr, previously namedServer.PublicAddrCloses #23693