I'm trying to replace the following lines
<application-bnd>
<security-role name="appAdmin">
<user name="appadmin"/>
</security-role>
<security-role name="RestAdmin">
<user name="appadmin"/>
</security-role>
<security-role name="ConsoleAdmin">
<user name="appadmin"/>
</security-role>
<security-role name="ConsoleUser">
<special-subject type="ALL_AUTHENTICATED_USERS" />
</security-role>
</application-bnd>
to
<application-bnd>
<security-role name="ALL_AUTHENTICATED_CONTAINER">
<special-subject type="ALL_AUTHENTICATED_USERS"/>
</security-role>
</application-bnd>
with sed command.
- application-bnd element is part section of big xml, I just want to find the multiple lines with above features, then replace it.
- The number of security-role elements is not fixed. Any suggestions?