mirror of
https://github.com/gogrlx/nats-server.git
synced 2026-04-02 03:38:42 -07:00
Only pass through to system account for account info api
Signed-off-by: Derek Collison <derek@nats.io>
This commit is contained in:
@@ -614,8 +614,8 @@ func (js *jetStream) apiDispatch(sub *subscription, c *client, acc *Account, sub
|
||||
|
||||
hdr, _ := c.msgParts(rmsg)
|
||||
if len(getHeader(ClientInfoHdr, hdr)) == 0 {
|
||||
// Check of this is the system account. We will let these through.
|
||||
if s.SystemAccount() != acc {
|
||||
// Check if this is the system account. We will let these through for the account info only.
|
||||
if s.SystemAccount() != acc || subject != JSApiAccountInfo {
|
||||
return
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user