Fix share key pattern matching

Fixes https://github.com/owncloud/core/issues/11127

But there's another failing pattern, unit test will fail.
Still looking for a solution...
Doesn't we have the same problem again, that we could match the wrong share key with preg_match() ?