You can clone with
Right now boto encapsulates the credential discovery logic in boto/provider:Provider.get_credentials.
The problem is that relying on this logic in any application exposes implementation details that we'd rather hide.
It would be ideal if we could, say, pass a list of credentials providers into Provider or AWSAuthConnection. I think the way the ruby aws-sdk library works reflects the extensibility that we're looking for.
I'd be open to a change which implements something similar to the Ruby SDK. In the meantime it should be fairly simple to roll your own credential discovery mechanism and pass the credentials into any new connection object you create. Is there some reason you cannot do that?
I've been able to work around it by doing something like this
but this is far from clean