@Override public ReceivePack create(Object req, Repository db) throws ServiceNotEnabledException { throw new ServiceNotEnabledException(); } };
@Override public UploadPack create(Object req, Repository db) throws ServiceNotEnabledException { throw new ServiceNotEnabledException(); } };
@Override public void access(HttpServletRequest req, Repository db) throws ServiceNotEnabledException { throw new ServiceNotEnabledException(); } };
public ReceivePack create(Object req, Repository db) throws ServiceNotEnabledException { throw new ServiceNotEnabledException(); } };
@Override public UploadPack create(Object req, Repository db) throws ServiceNotEnabledException { throw new ServiceNotEnabledException(); } };
public UploadPack create(Object req, Repository db) throws ServiceNotEnabledException { throw new ServiceNotEnabledException(); } };
@Override public void access(HttpServletRequest req, Repository db) throws ServiceNotEnabledException { throw new ServiceNotEnabledException(); } };
@Override public ReceivePack create(Object req, Repository db) throws ServiceNotEnabledException { throw new ServiceNotEnabledException(); } };
/** * Determine if access to any bare file of the repository is allowed. * <p> * This method silently succeeds if the request is allowed, or fails by * throwing a checked exception if access should be denied. * <p> * The default implementation of this method checks {@code http.getanyfile}, * throwing {@link ServiceNotEnabledException} if it was explicitly set to * {@code false}, and otherwise succeeding silently. * * @param req * current HTTP request, in case information from the request may * help determine the access request. * @param db * the repository the request would obtain a bare file from. * @throws ServiceNotEnabledException * bare file access is not allowed on the target repository, by * any user, for any reason. * @throws ServiceNotAuthorizedException * bare file access is not allowed for this HTTP request and * repository, such as due to a permission error. */ public void access(HttpServletRequest req, Repository db) throws ServiceNotEnabledException, ServiceNotAuthorizedException { if (!isEnabled(db)) throw new ServiceNotEnabledException(); } }
/** * Determine if access to any bare file of the repository is allowed. * <p> * This method silently succeeds if the request is allowed, or fails by * throwing a checked exception if access should be denied. * <p> * The default implementation of this method checks {@code http.getanyfile}, * throwing {@link ServiceNotEnabledException} if it was explicitly set to * {@code false}, and otherwise succeeding silently. * * @param req * current HTTP request, in case information from the request may * help determine the access request. * @param db * the repository the request would obtain a bare file from. * @throws ServiceNotEnabledException * bare file access is not allowed on the target repository, by * any user, for any reason. * @throws ServiceNotAuthorizedException * bare file access is not allowed for this HTTP request and * repository, such as due to a permission error. */ public void access(HttpServletRequest req, Repository db) throws ServiceNotEnabledException, ServiceNotAuthorizedException { if (!isEnabled(db)) throw new ServiceNotEnabledException(); } }
public UploadPack create(final HttpServletRequest req, final Repository db) throws ServiceNotEnabledException, ServiceNotAuthorizedException { if (db.getConfig().get(CONFIG).enabled) return new UploadPack(db); else throw new ServiceNotEnabledException(); } }
public UploadPack create(final HttpServletRequest req, final Repository db) throws ServiceNotEnabledException, ServiceNotAuthorizedException { if (db.getConfig().get(CONFIG).enabled) return new UploadPack(db); else throw new ServiceNotEnabledException(); } }
public ReceivePack create(final HttpServletRequest req, final Repository db) throws ServiceNotEnabledException, ServiceNotAuthorizedException { final ServiceConfig cfg = db.getConfig().get(CONFIG); String user = req.getRemoteUser(); if (cfg.set) { if (cfg.enabled) { if (user == null || "".equals(user)) user = "anonymous"; return createFor(req, db, user); } throw new ServiceNotEnabledException(); } if (user != null && !"".equals(user)) return createFor(req, db, user); throw new ServiceNotAuthorizedException(); }
public ReceivePack create(final HttpServletRequest req, final Repository db) throws ServiceNotEnabledException, ServiceNotAuthorizedException { final ServiceConfig cfg = db.getConfig().get(CONFIG); String user = req.getRemoteUser(); if (cfg.set) { if (cfg.enabled) { if (user == null || "".equals(user)) user = "anonymous"; return createFor(req, db, user); } throw new ServiceNotEnabledException(); } if (user != null && !"".equals(user)) return createFor(req, db, user); throw new ServiceNotAuthorizedException(); }
leader = leaders.get(repo); } catch (URISyntaxException err) { throw new ServiceNotEnabledException( KetchText.get().invalidFollowerUri, err);