You first have to create an ID for your input, assign it to a variable:
var element = document.getElementById("inputConcatenar");
Then you give name
a new value, in which case I've used the Replace that will look for a string that you pass and replace with another.
element.name = element.name.replace("strConcatenada", strConcatenada)
console.log(element.name);
I made it as simple as possible, the result is this, it follows the console.log
of name. If you want to remove the "<%% >" just pass <% strConcatenada% > to Replace, thus:
replace("<%strConcatenada%>", strConcatenada)
<input id="inputConcatenar" type="hidden" name="<%=strConcatenada%>W_TESTE_AUTO" value="1">
<script type="text/javascript">
var strConcatenada = "STR_VARIAVEL.";
var element = document.getElementById("inputConcatenar");
element.name = element.name.replace("strConcatenada", strConcatenada)
console.log(element.name);
</script>