Buggy code:
public final class ManagedServerOperationsFactory { private static final ModelNode EMPTY = new ModelNode ( ) ; public static ModelNode createBootUpdates ( final String serverName , final ModelNode domainModel , final ModelNode hostModel , final DomainController domainController , final ExpressionResolver expressionResolver ) { } private final String serverName ; private final ModelNode domainModel ; private final ModelNode hostModel ; private final ModelNode serverModel ; private final ModelNode serverGroup ; private final String serverGroupName ; private final String profileName ; private final DomainController domainController ; private final ExpressionResolver expressionResolver ; ManagedServerOperationsFactory ( final String serverName , final ModelNode domainModel , final ModelNode hostModel , final DomainController domainController , final ExpressionResolver expressionResolver ) { } private ModelNode resolveExpressions ( final ModelNode unresolved ) { } ModelNode getBootUpdates ( ) { } private void setServerGroupHost ( ManagedServerOperationsFactory . ModelNodeList updates ) { } private void addNamespaces ( List < ModelNode > updates ) { } private void addNamespaces ( Map < String , ModelNode > map , ModelNode namespaces ) { } private void addProfileName ( List < ModelNode > updates ) { } private void addSchemaLocations ( List < ModelNode > updates ) { } private void addSchemaLocations ( Map < String , ModelNode > map , ModelNode namespaces ) { } private void addExtensions ( List < ModelNode > updates ) { } private void addExtensions ( Set < String > extensionNames , ModelNode extensions ) { } private void addPaths ( List < ModelNode > updates ) { } private void addPaths ( Map < String , ModelNode > map , ModelNode path ) { } private void addSystemProperties ( List < ModelNode > updates ) { } private Map < String , String > getAllSystemProperties ( boolean boottimeOnly ) { } private void addSystemProperties ( final ModelNode source , final Map < String , String > props , boolean boottimeOnly ) { } private void addVault ( List < ModelNode > updates ) { } private void addVault ( List < ModelNode > updates , ModelNode vaultNode ) { } private void addManagementSecurityRealms ( List < ModelNode > updates ) { } private void addManagementComponentComponent ( ModelNode realm , ModelNode parentAddress , String key , List < ModelNode > updates ) { } private void addAuditLog ( ManagedServerOperationsFactory . ModelNodeList updates ) { } private void addManagementConnections ( List < ModelNode > updates ) { } private void addManagementAuthorization ( ManagedServerOperationsFactory . ModelNodeList updates ) { ModelNode domainConfig = domainModel . get ( CORE_SERVICE , MANAGEMENT , ACCESS , AUTHORIZATION ) ; if ( domainConfig . isDefined ( ) ) { ModelNode baseAddress = new ModelNode ( ) ; baseAddress . add ( CORE_SERVICE , MANAGEMENT ) ; baseAddress . add ( ACCESS , AUTHORIZATION ) ; if ( domainConfig . hasDefined ( PROVIDER ) ) { ModelNode providerOp = Util . getWriteAttributeOperation ( baseAddress , PROVIDER , domainConfig . get ( PROVIDER ) ) ; updates . add ( providerOp ) ; } addRoleMappings ( domainConfig , baseAddress , updates ) ; ManagedServerOperationsFactory . convertSimpleResources ( domainConfig , SERVER_GROUP_SCOPED_ROLE , baseAddress , updates ) ; ManagedServerOperationsFactory . convertSimpleResources ( domainConfig , HOST_SCOPED_ROLE , baseAddress , updates ) ; if ( domainConfig . hasDefined ( CONSTRAINT ) ) { ModelNode constraints = domainConfig . get ( CONSTRAINT ) ; if ( constraints . hasDefined ( APPLICATION_CLASSIFICATION ) ) { ManagedServerOperationsFactory . convertSimpleResources ( constraints . get ( APPLICATION_CLASSIFICATION ) , APPLICATION_CLASSIFICATION , baseAddress , updates ) ; } if ( constraints . hasDefined ( SENSITIVITY_CLASSIFICATION ) ) { ManagedServerOperationsFactory . convertSimpleResources ( constraints . get ( SENSITIVITY_CLASSIFICATION ) , SENSITIVITY_CLASSIFICATION , baseAddress , updates ) ; } if ( constraints . hasDefined ( VAULT_EXPRESSION ) ) { ModelNode address = baseAddress . clone ( ) . add ( CONSTRAINT , VAULT_EXPRESSION ) ; ModelNode ve = constraints . get ( VAULT_EXPRESSION ) ; <START_BUG> for ( AttributeDefinition ad : SensitivityResourceDefinition . getWritableAttributeDefinitions ( ) ) { <END_BUG> String attr = ad . getName ( ) ; if ( ve . hasDefined ( attr ) ) { updates . add ( Util . getWriteAttributeOperation ( address , attr , ve . get ( attr ) ) ) ; } } } } } } private void addRoleMappings ( ModelNode accessControl , ModelNode baseAddress , ManagedServerOperationsFactory . ModelNodeList updates ) { } private void addInterfaces ( List < ModelNode > updates ) { } private static ModelNode getAddInterfaceOperation ( PathAddress address , ModelNode criteria ) { } private void addInterfaces ( Map < String , ModelNode > map , ModelNode iface ) { } private void addSocketBindings ( List < ModelNode > updates , int portOffSet , String bindingRef ) { } private void mergeBindingGroups ( List < ModelNode > updates , Map < String , ModelNode > groups , final String groupName , ModelNode group , Set < String > processed ) { } private void addSocketBindings ( List < ModelNode > updates , ModelNode group , final String groupName , ModelNode defaultInterface ) { } public static ModelNode getLocalSocketBindingAddOperation ( final PathAddress address , final ModelNode localDestinationOutboundSocketBinding ) { } public static ModelNode getRemoteSocketBindingAddOperation ( final PathAddress address , final ModelNode remoteDestinationOutboundSocketBinding ) { } private void addSubsystems ( List < ModelNode > updates ) { } private void addDeployments ( List < ModelNode > updates ) { } public void addDeploymentOverlays ( final List < ModelNode > updates ) { } private ModelNode addAddNameAndAddress ( ModelNode op , PathAddress address ) { } private ModelNode addAddNameAndAddress ( ModelNode op , ModelNode address ) { } private static void convertSimpleResources ( ModelNode model , String type , ModelNode baseAddress , ManagedServerOperationsFactory . ModelNodeList updates ) { } private static void convertAttributesToParams ( ModelNode value , ModelNode addOp ) { } private class ModelNodeList extends AbstractList < ModelNode > implements List < ModelNode > { private final ModelNode model = new ModelNode ( ) . setEmptyList ( ) ; @ Override public boolean add ( ModelNode modelNode ) { }

Fix:
for ( AttributeDefinition ad : SensitivityResourceDefinition . getWritableVaultAttributeDefinitions ( ) ) {