vBulletin: User field choices keys may get mangled

Kirby

Well-known member
Affected version
1.6.1
XFI\Import\Importer\vBulletin::getProfileFieldChoices
PHP:
$choiceData = $this->decodeValue($field['data'], 'serialized-array');

[...]

foreach ($choiceData AS $key => $choice)
{
    if ($choiceId = $this->convertToId($choice, 23))

$field['data'] may contain data that is not UTF-8, so if this is passed to convertToId the string may get mangled ginving somewhat inconsistent results.

Changing this to
PHP:
if ($choiceId = $this->convertToId($this->convertToUtf8($choice), 23))
seems to fix this.
 
Back
Top Bottom