title: S3 Policy removing dashes in Principal java sdk + Ceph S3
body: <p>I am trying to use the aws sdk to create policies in a ceph s3 cluster. When creating in Java the statement of the policy, in the principal it removes by default the dashes.
  I could confirm from the policy generator that this happens when you generate policies in AWS.</p>
  <p>Looking at the <a href="https://docs.aws.amazon.com/AWSJavaSDK/latest/javadoc/com/amazonaws/auth/policy/Principal.html" rel="nofollow noreferrer">https://docs.aws.amazon.com/AWSJavaSDK/latest/javadoc/com/amazonaws/auth/policy/Principal.html</a></p>
  <p>when using Principal(String provider, String id, boolean stripHyphen)
  It would still strip them if I use as provider the AWS.
  If I choose another provider for the stripHyphen to not happen, then the policies will not be applied in CephS3 that expects AWS as well.</p>
  <p>What is the reason for the hyphens to be removed if the user id, the account or the bucket can all have dashes in their name?</p>
  <p>Should I replace the aws sdk with something else for CephS3?</p>