Buggy code:
public class NativeManagementAddHandler extends AbstractAddStepHandler { public static final NativeManagementAddHandler INSTANCE = new NativeManagementAddHandler ( ) ; public static final String OPERATION_NAME = ModelDescriptionConstants . ADD ; protected void populateModel ( ModelNode operation , ModelNode model ) throws OperationFailedException { } protected void performRuntime ( OperationContext context , ModelNode operation , ModelNode model , ServiceVerificationHandler verificationHandler , List < ServiceController < ? > > newControllers ) throws OperationFailedException { } private static void validateAndSet ( final AttributeDefinition definition , final ModelNode operation , final ModelNode subModel ) throws OperationFailedException { } private static ModelNode validateResolvedModel ( final AttributeDefinition definition , final OperationContext context , final ModelNode subModel ) throws OperationFailedException { } static void installNativeManagementConnector ( final OperationContext context , final ModelNode model , final ServiceName endpointName , final ServiceTarget serviceTarget , final ServiceVerificationHandler verificationHandler , final List < ServiceController < ? > > newControllers ) throws OperationFailedException { ServiceName socketBindingServiceName = null ; ServiceName interfaceSvcName = null ; int port = 0 ; final ModelNode socketBindingNode = NativeManagementAddHandler . validateResolvedModel ( SOCKET_BINDING , context , model ) ; if ( socketBindingNode . isDefined ( ) ) { final String bindingName = SOCKET_BINDING . resolveModelAttribute ( context , model ) . asString ( ) ; socketBindingServiceName = JBOSS_BINDING_NAME . append ( bindingName ) ; } else { String interfaceName = INTERFACE . resolveModelAttribute ( context , model ) . asString ( ) ; interfaceSvcName = JBOSS_NETWORK_INTERFACE . append ( interfaceName ) ; port = NATIVE_PORT . resolveModelAttribute ( context , model ) . asInt ( ) ; } ServiceName realmSvcName = null ; final ModelNode realmNode = SECURITY_REALM . resolveModelAttribute ( context , model ) ; if ( realmNode . isDefined ( ) ) { realmSvcName = BASE_SERVICE_NAME . append ( realmNode . asString ( ) ) ; } else { Logger . getLogger ( "org.jboss.as" ) . warn ( "No<seq2seq4repair_space>security<seq2seq4repair_space>realm<seq2seq4repair_space>defined<seq2seq4repair_space>for<seq2seq4repair_space>native<seq2seq4repair_space>management<seq2seq4repair_space>service,<seq2seq4repair_space>all<seq2seq4repair_space>access<seq2seq4repair_space>will<seq2seq4repair_space>be<seq2seq4repair_space>unrestricted." ) ; } <START_BUG> ServiceName tmpDirPath = JBOSS . append ( "server" , "path" , "jboss.server.temp.dir" ) ; <END_BUG> RemotingServices . installSecurityServices ( serviceTarget , MANAGEMENT_CONNECTOR , realmSvcName , null , tmpDirPath , verificationHandler , newControllers ) ; if ( socketBindingServiceName == null ) { ManagementRemotingServices . installConnectorServicesForNetworkInterfaceBinding ( serviceTarget , endpointName , MANAGEMENT_CONNECTOR , interfaceSvcName , port , EMPTY , verificationHandler , newControllers ) ; } else { ManagementRemotingServices . installConnectorServicesForSocketBinding ( serviceTarget , endpointName , MANAGEMENT_CONNECTOR , socketBindingServiceName , EMPTY , verificationHandler , newControllers ) ; } } }

Fix:
ServiceName tmpDirPath = JBOSS . append ( "server" , "path" , "jboss.home.dir" ) ;