};
HylaFAXServer::booltag HylaFAXServer::booleans[] = {
{ "allowsorting", &HylaFAXServer::allowSorting, true },
+{ "publicjobq", &HylaFAXServer::publicJobQ, false },
};
void
time_t discTime; // time to disconnect service
time_t denyTime; // time to deny service
u_int jobProtection; // Protection to use on Jobs
+ bool publicJobQ; // Public/protection on recvq?
bool allowSorting; // Allow client to make us sort
/*
* User authentication and login-related state.
bool reject;
if (req->readQFile(reject) && !reject) {
Sys::close(req->fd), req->fd = -1;
- if (checkAccess(*req, T_JOB, A_READ) )
+ if (publicJobQ)
+ return (req);
+ if (req->owner == the_user)
+ return (req);
+ if (checkFileRights(A_READ, sb) )
return (req);
emsg = "Permission denied";
delete req;
*/
bool
-HylaFAXServer::isVisibleSendQFile(const char* filename, const struct stat&)
+HylaFAXServer::isVisibleSendQFile(const char* filename, const struct stat& sb)
{
if (filename[0] == 'q') {
fxStr emsg;
Job* job = findJob(&filename[1], emsg);
- if (job && checkAccess(*job, T_JOB, A_READ))
+ if (job && checkFileRights(R_OK, sb) )
return true;
}
return false;