MT#9239 Allow '*' as first rewrite char.

(cherry picked from commit 86a2b4d9da5ddf01feae3eba649cf2b644e6945e)
(cherry picked from commit f5e9c72734d8ee2b9f4070931a4c1cb62e4d924f)