Colleagues, I found the solution.
community-home.jsp and collection-home.jsp files it is necessary to insert the following line in the header:
<% @ page import = "org.dspace.eperson.EPerson"%>
then you can use the function that validates the logged in user:
// Is anyone logged in?
EPerson user = (EPerson) request.getAttribute ("dspace.current.user");
That way, you can manipulate any html attribute to be shown to the user.
So, I do to manipulates statistics. In community-home.jps, I added the following rule:
<%
if(user!=null)
{
%>
<a class="statisticsLink btn btn-info" href="<%= request.getContextPath() %>/handle/<%= community.getHandle() %>/statistics"><fmt:message key="jsp.community-home.display-statistics"/></a>
<%
}
%>
and collection-home.jsp, I added the following rule:
<%
if(user!=null)
{
%>
<a class="statisticsLink btn btn-info" href="<%= request.getContextPath() %>/handle/<%= collection.getHandle() %>/statistics"><fmt:message key="jsp.collection-home.display-statistics"/></a>
<%
}
%>