The nested OriginPattern class in CorsConfiguration is amazingly useful and should be available for re-use by applications.

Comment From: pivotal-cla

@Tr1ple-F Please sign the Contributor License Agreement!

Click here to manually synchronize the status of this Pull Request.

See the FAQ for frequently asked questions.

Comment From: pivotal-cla

@Tr1ple-F Thank you for signing the Contributor License Agreement!

Comment From: sbrannen

Hi @Tr1ple-F,

What concrete need do you have for using OriginPattern in your own application?

Comment From: Tr1ple-F

I am extending OAuth2RedirectStrategy and only want to allow a given subset of redirect patterns (similar to the CORS Origins). For this it seems better to me to reuse the existing OriginPattern class.

Also I don't see a reason why it should be specifically private.