-
Notifications
You must be signed in to change notification settings - Fork 1.1k
ENT-14161: Limit RPC login attempts #8033
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
ENT-14161: Limit RPC login attempts #8033
Conversation
node/src/main/kotlin/net/corda/node/internal/security/RPCSecurityManagerImpl.kt
Outdated
Show resolved
Hide resolved
node/src/main/kotlin/net/corda/node/internal/security/RPCSecurityManagerImpl.kt
Outdated
Show resolved
Hide resolved
node/src/main/kotlin/net/corda/node/internal/security/RPCSecurityManagerImpl.kt
Outdated
Show resolved
Hide resolved
node/src/main/kotlin/net/corda/node/internal/security/RPCSecurityManagerImpl.kt
Outdated
Show resolved
Hide resolved
node/src/main/kotlin/net/corda/node/internal/security/RPCSecurityManagerImpl.kt
Outdated
Show resolved
Hide resolved
node/src/main/kotlin/net/corda/node/internal/security/RPCSecurityManagerImpl.kt
Outdated
Show resolved
Hide resolved
...src/main/kotlin/net/corda/node/services/messaging/RateLimitingActiveMQJAASSecurityManager.kt
Outdated
Show resolved
Hide resolved
rick-r3
left a comment
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.
I think the algorithm and implementation is now basically right. Just made some detailed comments on the code now.
...src/main/kotlin/net/corda/node/services/messaging/RateLimitingActiveMQJAASSecurityManager.kt
Outdated
Show resolved
Hide resolved
...src/main/kotlin/net/corda/node/services/messaging/RateLimitingActiveMQJAASSecurityManager.kt
Outdated
Show resolved
Hide resolved
...src/main/kotlin/net/corda/node/services/messaging/RateLimitingActiveMQJAASSecurityManager.kt
Outdated
Show resolved
Hide resolved
...src/main/kotlin/net/corda/node/services/messaging/RateLimitingActiveMQJAASSecurityManager.kt
Outdated
Show resolved
Hide resolved
...src/main/kotlin/net/corda/node/services/messaging/RateLimitingActiveMQJAASSecurityManager.kt
Outdated
Show resolved
Hide resolved
...src/main/kotlin/net/corda/node/services/messaging/RateLimitingActiveMQJAASSecurityManager.kt
Outdated
Show resolved
Hide resolved
...src/main/kotlin/net/corda/node/services/messaging/RateLimitingActiveMQJAASSecurityManager.kt
Outdated
Show resolved
Hide resolved
...src/main/kotlin/net/corda/node/services/messaging/RateLimitingActiveMQJAASSecurityManager.kt
Outdated
Show resolved
Hide resolved
...src/main/kotlin/net/corda/node/services/messaging/RateLimitingActiveMQJAASSecurityManager.kt
Outdated
Show resolved
Hide resolved
| log.warn(printWarnMessage(user, remaining)) | ||
| throw FailedLoginException(printWarnMessage(user, remaining)) |
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.
Just a comment, if these logs turn out to be an issue. Then log4j2.xml can be used to filter them out if needed.
Added optional RPC authentication rate-limiting to protect nodes from brute-force or dictionary attacks. When enabled, repeated failed logins trigger an exponential backoff, temporarily blocking further attempts. All parameters — base delay, maximum delay, and attempt expiry — are fully configurable programmatically and via node.conf, while the default behaviour remains unchanged (no rate limiting unless explicitly enabled).
PR Checklist:
https://docs.r3.com/release-notes.html)?Thanks for your code, it's appreciated! :)