use of com.pspace.ifs.ksan.gw.identity.S3Bucket in project ksan by infinistor.
the class DeleteBucketCors method process.
@Override
public void process() throws GWException {
logger.info(GWConstants.LOG_DELETE_BUCKET_CORS_START);
String bucket = s3Parameter.getBucketName();
initBucketInfo(bucket);
S3Bucket s3Bucket = new S3Bucket();
s3Bucket.setCors(getBucketInfo().getCors());
s3Bucket.setAccess(getBucketInfo().getAccess());
s3Parameter.setBucket(s3Bucket);
GWUtils.checkCors(s3Parameter);
if (s3Parameter.isPublicAccess() && GWUtils.isIgnorePublicAcls(s3Parameter)) {
throw new GWException(GWErrorCode.ACCESS_DENIED, s3Parameter);
}
updateBucketCors(bucket, "");
s3Parameter.getResponse().setStatus(HttpServletResponse.SC_NO_CONTENT);
}
use of com.pspace.ifs.ksan.gw.identity.S3Bucket in project ksan by infinistor.
the class DeleteBucketObjectLock method process.
@Override
public void process() throws GWException {
logger.info(GWConstants.LOG_DELETE_BUCKET_OBJECT_LOCK_START);
String bucket = s3Parameter.getBucketName();
initBucketInfo(bucket);
S3Bucket s3Bucket = new S3Bucket();
s3Bucket.setCors(getBucketInfo().getCors());
s3Bucket.setAccess(getBucketInfo().getAccess());
s3Parameter.setBucket(s3Bucket);
GWUtils.checkCors(s3Parameter);
if (s3Parameter.isPublicAccess() && GWUtils.isIgnorePublicAcls(s3Parameter)) {
throw new GWException(GWErrorCode.ACCESS_DENIED, s3Parameter);
}
updateBucketObjectLock(bucket, "");
s3Parameter.getResponse().setStatus(HttpServletResponse.SC_NO_CONTENT);
}
use of com.pspace.ifs.ksan.gw.identity.S3Bucket in project ksan by infinistor.
the class DeleteBucketPolicy method process.
@Override
public void process() throws GWException {
logger.info(GWConstants.LOG_DELETE_BUCKET_POLICY_START);
String bucket = s3Parameter.getBucketName();
initBucketInfo(bucket);
S3Bucket s3Bucket = new S3Bucket();
s3Bucket.setCors(getBucketInfo().getCors());
s3Bucket.setAccess(getBucketInfo().getAccess());
s3Parameter.setBucket(s3Bucket);
GWUtils.checkCors(s3Parameter);
if (s3Parameter.isPublicAccess() && GWUtils.isIgnorePublicAcls(s3Parameter)) {
throw new GWException(GWErrorCode.ACCESS_DENIED, s3Parameter);
}
updateBucketPolicy(bucket, "");
s3Parameter.getResponse().setStatus(HttpServletResponse.SC_NO_CONTENT);
}
use of com.pspace.ifs.ksan.gw.identity.S3Bucket in project ksan by infinistor.
the class DeleteBucketTagging method process.
@Override
public void process() throws GWException {
logger.info(GWConstants.LOG_DELETE_BUCKET_TAGGING_START);
String bucket = s3Parameter.getBucketName();
initBucketInfo(bucket);
S3Bucket s3Bucket = new S3Bucket();
s3Bucket.setCors(getBucketInfo().getCors());
s3Bucket.setAccess(getBucketInfo().getAccess());
s3Parameter.setBucket(s3Bucket);
GWUtils.checkCors(s3Parameter);
if (s3Parameter.isPublicAccess() && GWUtils.isIgnorePublicAcls(s3Parameter)) {
throw new GWException(GWErrorCode.ACCESS_DENIED, s3Parameter);
}
updateBucketTagging(bucket, "");
s3Parameter.getResponse().setStatus(HttpServletResponse.SC_NO_CONTENT);
}
use of com.pspace.ifs.ksan.gw.identity.S3Bucket in project ksan by infinistor.
the class DeleteBucketWebsite method process.
@Override
public void process() throws GWException {
logger.info(GWConstants.LOG_DELETE_BUCKET_WEBSITE_START);
String bucket = s3Parameter.getBucketName();
initBucketInfo(bucket);
S3Bucket s3Bucket = new S3Bucket();
s3Bucket.setCors(getBucketInfo().getCors());
s3Bucket.setAccess(getBucketInfo().getAccess());
s3Parameter.setBucket(s3Bucket);
GWUtils.checkCors(s3Parameter);
if (s3Parameter.isPublicAccess() && GWUtils.isIgnorePublicAcls(s3Parameter)) {
throw new GWException(GWErrorCode.ACCESS_DENIED, s3Parameter);
}
updateBucketWeb(bucket, "");
s3Parameter.getResponse().setStatus(HttpServletResponse.SC_NO_CONTENT);
}
Aggregations