String user;
if(pwd!=null) user=Messages.PAMSecurityRealm_User(pwd.getLoginName());
else user=Messages.PAMSecurityRealm_CurrentUser();
String group;
Group g = api.getgrgid(st.gid());
if(g!=null) group=g.getName();
else group=String.valueOf(st.gid());
if ((st.mode()&FileStat.S_IRGRP)!=0) {
// the file is readable to group. Jenkins should be in the right group, then
return FormValidation.error(Messages.PAMSecurityRealm_BelongToGroup(user, group));