Split AppBitsController into separate upload and download controllers

* In preparation for handling auth token differently on app bits upload.

[#68014448]

Signed-off-by: James Myers <jmyers@pivotallabs.com>
Update cf-uaa-lib gem to 2.0.1

* Minor refactorings in uaa_util on account of change from CF::UAA::Misc
to CF::UAA::Info in 2.0.0

[#68014448]

Signed-off-by: James Myers <jmyers@pivotallabs.com>
Extract SecurityContext setup from CC::Controller into separate class

* This responsibility moved to SecurityContextConfigurer class
* Move CF::UAA exception handling and logging into UaaTokenDecoder
* Remove support for deprecated bootstrap_admin_email config parameter

[#68014448]

Signed-off-by: James Myers <jmyers@pivotallabs.com>
Remove deprecated bootstrap_admin_email property from config and templates

[#68014448]

Signed-off-by: James Myers <jmyers@pivotallabs.com>
Change app bits upload controller to reauthorize with grace period

* Grace period can be set in config, defaults to 0 in controller if
  absent
* UaaTokenDecoder uses grace period when decoding auth token
* Uses new version of cf-uaa-lib that supports decoding at a reference
  timestamp

[#68014448]

Signed-off-by: Eric Malm <emalm@pivotallabs.com>
Remove unused CF::UAA stub from spec_helper

* It seems as if we used to have a controller action during a before(:all)
  which required this stub on validation_key in order to force symmetric key
  behavior.

Signed-off-by: Kai Zhang <kaizhang@cn.ibm.com>
Allow app_bits_upload_grace_period_in_seconds to be configurable

* when it is not specified we provide a default value of 0 seconds.

[#68014448]

Signed-off-by: Kai Zhang <kaizhang@cn.ibm.com>
Split uaa_util.rb and specs into separate files

[#68014448]

Signed-off-by: Kai Zhang <kaizhang@cn.ibm.com>
Remove mock of uaa_token_coder from symmetric_key spec

[#68014448]

Signed-off-by: Kai Zhang <kaizhang@cn.ibm.com>
Reset app_bits_upload_grace_period_in_seconds to 0 when it's negative

* Hopefully we will sanitize other invalid values in the config for the
  future
[#68014448]

Signed-off-by: Kai Zhang <kaizhang@cn.ibm.com>