in ruby, with the optional /W matching: 
>> "/W\"this is an etag\"".gsub /(?:\/W)*\"(.*)\"$/, '\1'
=> "this is an etag"
>> "\"this is an etag\"".gsub /(?:\/W)*\"(.*)\"$/, '\1'
=> "this is an etag"
>> "this is an etag".gsub /(?:\/W)*\"(.*)\"$/, '\1'
=> "this is an etag"