Extract rw_config into module, and clean it up a little.

### WHAT

Move `rw_config` into a module, and include that module in `Authlogic::ActsAsAuthentic::Base` and `Authlogic::Session::Foundation`. Tests included.

### WHY

Currently `rw_config` is defined in the 2 modules, but their implementation is slightly different. We should make this easier to understand and test it.
the previous way of doing this (cloning the config) was a [relic of Rails 3.1 compatibility](https://github.com/binarylogic/authlogic/pull/254/files#diff-5feb6249381e7f033273d34774b4b4e6L80), so that subclasses don't overwrite their parent class's config. We can achieve the same effect using `merge`.