Refactor how the "length" parameter is obtained for HmacKeyParams.

This makes it more clear to the caller that the length parameter is optional and may not be present. Being more defensive is desirable, since I saw a code review which tried to use the value without checking if it was present.

BUG=245025

Review URL: https://chromiumcodereview.appspot.com/23455017

git-svn-id: svn://svn.chromium.org/blink/trunk@156972 bbb929c8-8fbe-4397-9dbb-9b2b20218538