WIP: Add session hash and remote CCS

PR so this can be reviewed.
We're going to have to revisit this one...