HEX
Server: Apache/2.4.65 (Debian)
System: Linux 88f31f35b0b8 6.1.0-38-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.147-1 (2025-08-02) x86_64
User: www-data (33)
PHP: 8.2.29
Disabled: NONE
Upload Files
File: /var/www/html/wp-content/plugins/malcare-security/wp_2fa/utils.php
<?php
if (!defined('ABSPATH')) exit;

if (!class_exists('MCWP2FAUtils')) :
	class MCWP2FAUtils {
		public static function getSecretInfo($info) {
			$default_info = array('secret' => null, 'is_encrypted' => null);

			if (empty($info) || !array_key_exists('secret', $info) || empty($info['secret']) ||
					!array_key_exists('is_encrypted', $info) || !is_bool($info['is_encrypted'])) {
				return $default_info;
			}

			$secret = base64_decode($info['secret']);
			if ($secret === false) {
				return $default_info;
			}

			return array('secret' => $secret, 'is_encrypted' => $info['is_encrypted']);
		}
	}
endif;