public JmxAuditLoggerResourceDefinition(final ManagedAuditLogger auditLogger) { super(PATH_ELEMENT, JMXExtension.getResourceDescriptionResolver("audit-log"), new AuditLoggerAddHandler(auditLogger), new AuditLoggerRemoveHandler(auditLogger)); this.auditLogger = auditLogger; }
public JmxAuditLogHandlerReferenceResourceDefinition(ManagedAuditLogger auditLogger) { //Make a remove reload required. Handlers using more complex formatters in the future will not like being stopped and started at runtime super(PATH_ELEMENT, JMXExtension.getResourceDescriptionResolver("audit-log.handler"), new AuditLogHandlerReferenceAddHandler(auditLogger), new AuditLogHandlerReferenceRemoveHandler(auditLogger)); }
static AccessAuditContext currentAccessAuditContext() { return createAccessAuditContextActions().currentContext(); }
ExposeModelResource(PathElement pathElement, ManagedAuditLogger auditLoggerInfo, JmxAuthorizer authorizer, SimpleAttributeDefinition domainName, SimpleAttributeDefinition...otherAttributes) { super(pathElement, JMXExtension.getResourceDescriptionResolver(CommonAttributes.EXPOSE_MODEL + "." + pathElement.getValue()), new ShowModelAdd(auditLoggerInfo, authorizer, domainName, otherAttributes), new ShowModelRemove(auditLoggerInfo, authorizer)); this.auditLoggerInfo = auditLoggerInfo; this.authorizer = authorizer; this.domainName = domainName; }
@Override public void registerChildren(ManagementResourceRegistration resourceRegistration) { resourceRegistration.registerSubModel(new ExposeModelResourceResolved(auditLogger, authorizer)); resourceRegistration.registerSubModel(new ExposeModelResourceExpression(auditLogger, authorizer)); resourceRegistration.registerSubModel(RemotingConnectorResource.INSTANCE); resourceRegistration.registerSubModel(new JmxAuditLoggerResourceDefinition(auditLogger)); }
private JMXSubsystemRootResource(ManagedAuditLogger auditLogger, JmxAuthorizer authorizer, Supplier<SecurityIdentity> securityIdentitySupplier, RuntimeHostControllerInfoAccessor hostInfoAccessor) { super(new Parameters(PATH_ELEMENT, JMXExtension.getResourceDescriptionResolver(JMXExtension.SUBSYSTEM_NAME)) .setAddHandler(new JMXSubsystemAdd(auditLogger, authorizer, securityIdentitySupplier, hostInfoAccessor)) .setRemoveHandler(new JMXSubsystemRemove(auditLogger, authorizer, securityIdentitySupplier, hostInfoAccessor)) .addCapabilities(JMX_CAPABILITY) .setAccessConstraints(JMXExtension.JMX_SENSITIVITY_DEF)); this.auditLogger = auditLogger; this.authorizer = authorizer; this.securityIdentitySupplier = securityIdentitySupplier; this.hostInfoAccessor = hostInfoAccessor; }
static Caller createCaller(SecurityIdentity securityIdentity) { return createCallerActions().createCaller(securityIdentity); }
@Override protected void recreateParentService(OperationContext context, PathAddress parentAddress, ModelNode parentModel, ServiceVerificationHandler verificationHandler) throws OperationFailedException { JMXSubsystemAdd.INSTANCE.launchServices(context, parentModel, verificationHandler, null); }
@Override public ObjectInstance createMBean(String className, ObjectName name, ObjectName loaderName) { log(readOnly, CREATE_MBEAN, CREATE_MBEAN_SIG_2, className, name, loaderName); return null; }
ExposeModelResource(PathElement pathElement, ManagedAuditLogger auditLoggerInfo, JmxAuthorizer authorizer, Supplier<SecurityIdentity> securityIdentitySupplier, RuntimeHostControllerInfoAccessor hostInfoAccessor, SimpleAttributeDefinition domainName, SimpleAttributeDefinition...otherAttributes) { super(pathElement, JMXExtension.getResourceDescriptionResolver(CommonAttributes.EXPOSE_MODEL + "." + pathElement.getValue()), new ShowModelAdd(auditLoggerInfo, authorizer, securityIdentitySupplier, domainName, hostInfoAccessor, otherAttributes), new ShowModelRemove(auditLoggerInfo, authorizer, securityIdentitySupplier, hostInfoAccessor)); this.auditLoggerInfo = auditLoggerInfo; this.authorizer = authorizer; this.securityIdentitySupplier = securityIdentitySupplier; this.domainName = domainName; this.hostInfoAccessor = hostInfoAccessor; }
public JmxAuditLoggerResourceDefinition(final ManagedAuditLogger auditLogger) { super(PATH_ELEMENT, JMXExtension.getResourceDescriptionResolver("audit-log"), new AuditLoggerAddHandler(auditLogger), new AuditLoggerRemoveHandler(auditLogger)); this.auditLogger = auditLogger; }
public JmxAuditLogHandlerReferenceResourceDefinition(ManagedAuditLogger auditLogger) { //Make a remove reload required. Handlers using more complex formatters in the future will not like being stopped and started at runtime super(PATH_ELEMENT, JMXExtension.getResourceDescriptionResolver("audit-log.handler"), new AuditLogHandlerReferenceAddHandler(auditLogger), new AuditLogHandlerReferenceRemoveHandler(auditLogger)); }
@Override public void registerChildren(ManagementResourceRegistration resourceRegistration) { resourceRegistration.registerSubModel(new ExposeModelResourceResolved(auditLogger, authorizer, securityIdentitySupplier, hostInfoAccessor)); resourceRegistration.registerSubModel(new ExposeModelResourceExpression(auditLogger, authorizer, securityIdentitySupplier, hostInfoAccessor)); resourceRegistration.registerSubModel(RemotingConnectorResource.INSTANCE); resourceRegistration.registerSubModel(new JmxAuditLoggerResourceDefinition(auditLogger)); }
@Override protected void recreateParentService(OperationContext context, PathAddress parentAddress, ModelNode parentModel, ServiceVerificationHandler verificationHandler) throws OperationFailedException { JMXSubsystemAdd.launchServices(context, parentModel, verificationHandler, auditLoggerInfo, authorizer, null); }
@Override public ObjectInstance createMBean(String className, ObjectName name, ObjectName loaderName, Object[] params, String[] signature) { log(readOnly, CREATE_MBEAN, CREATE_MBEAN_SIG_4, className, name, loaderName, params, signature); return null; }
@Override protected void recreateParentService(OperationContext context, PathAddress parentAddress, ModelNode parentModel, ServiceVerificationHandler verificationHandler) throws OperationFailedException { JMXSubsystemAdd.INSTANCE.launchServices(context, parentModel, verificationHandler, null); }
@Override public Integer getMBeanCount() { log(readOnly, GET_MBEAN_COUNT, GET_MBEAN_COUNT_SIG); return null; }
@Override public ObjectInputStream deserialize(String className, byte[] data) { log(readOnly, DESERIALIZE, DESERIALIZE_SIG2, className, data); return null; }
@Override public ObjectInstance registerMBean(Object object, ObjectName name) { log(readOnly, REGISTER_MBEAN, REGISTER_MBEAN_SIG, object, name); return null; }
@Override public ClassLoaderRepository getClassLoaderRepository() { log(readOnly, GET_CLASSLOADER_REPOSITORY, GET_CLASSLOADER_REPOSITORY_SIG); return null; }