Merge pull request #13 from abbodi1406/master

Add support for Server editions
This commit is contained in:
luzea 2021-05-29 14:15:40 +02:00 committed by GitHub
commit f697574edd
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 44 additions and 14 deletions

View File

@ -233,6 +233,9 @@ function parseFetchUpdate($updateInfo, $out, $arch, $ring, $flight, $build, $sku
if($foundType == 'server') if($foundType == 'server')
$updateTitle = str_replace('Windows 10', 'Windows Server', $updateTitle); $updateTitle = str_replace('Windows 10', 'Windows Server', $updateTitle);
if($sku == 406)
$updateTitle = str_replace('Microsoft server operating system', 'Azure Stack HCI', $updateTitle);
if($foundType == 'sedimentpack') if($foundType == 'sedimentpack')
$updateTitle = $updateTitle.' - KB4023057'; $updateTitle = $updateTitle.' - KB4023057';

View File

@ -16,7 +16,7 @@ limitations under the License.
*/ */
function uupApiVersion() { function uupApiVersion() {
return '1.31.0'; return '1.31.1';
} }
require_once dirname(__FILE__).'/auths.php'; require_once dirname(__FILE__).'/auths.php';

View File

@ -77,6 +77,16 @@ function uupGetInfoTexts() {
'PPIPRO' => 'Windows 10 Team', 'PPIPRO' => 'Windows 10 Team',
'PROFESSIONAL' => 'Windows 10 Pro', 'PROFESSIONAL' => 'Windows 10 Pro',
'PROFESSIONALN' => 'Windows 10 Pro N', 'PROFESSIONALN' => 'Windows 10 Pro N',
'SERVERSTANDARD' => 'Windows Server Standard',
'SERVERSTANDARDCORE' => 'Windows Server Standard, Core',
'SERVERDATACENTER' => 'Windows Server Datacenter',
'SERVERDATACENTERCORE' => 'Windows Server Datacenter, Core',
'SERVERAZURESTACKHCICOR' => 'Azure Stack HCI',
'SERVERTURBINE' => 'Windows Server Datacenter Azure',
'SERVERTURBINECOR' => 'Windows Server Datacenter Azure, Core',
'SERVERSTANDARDACOR' => 'Windows Server Standard SAC',
'SERVERDATACENTERACOR' => 'Windows Server Datacenter SAC',
'SERVERARM64' => 'Windows Server ARM64',
); );
$allEditions = array( $allEditions = array(

View File

@ -26,7 +26,7 @@ function composeDeviceAttributes($flight, $ring, $build, $arch, $sku, $type) {
$arch = $arch[0]; $arch = $arch[0];
} }
if($sku == 125 || $sku == 126 || $sku == 7 || $sku == 8 || $sku == 120 || $sku == 145 || $sku == 146 || $sku == 168) if($sku == 125 || $sku == 126 || $sku == 7 || $sku == 8 || $sku == 12 || $sku == 13 || $sku == 79 || $sku == 80 || $sku == 120 || $sku == 145 || $sku == 146 || $sku == 147 || $sku == 148 || $sku == 159 || $sku == 160 || $sku == 406 || $sku == 407 || $sku == 408)
$blockUpgrades = 1; $blockUpgrades = 1;
$dvcFamily = 'Windows.Desktop'; $dvcFamily = 'Windows.Desktop';
@ -34,7 +34,7 @@ function composeDeviceAttributes($flight, $ring, $build, $arch, $sku, $type) {
if($sku == 119) { if($sku == 119) {
$dvcFamily = 'Windows.Team'; $dvcFamily = 'Windows.Team';
} }
if($sku == 7 || $sku == 8 || $sku == 120 || $sku == 145 || $sku == 146 || $sku == 168) { if($sku == 7 || $sku == 8 || $sku == 12 || $sku == 13 || $sku == 79 || $sku == 80 || $sku == 120 || $sku == 145 || $sku == 146 || $sku == 147 || $sku == 148 || $sku == 159 || $sku == 160 || $sku == 406 || $sku == 407 || $sku == 408) {
$dvcFamily = 'Windows.Server'; $dvcFamily = 'Windows.Server';
$insType = 'Server'; $insType = 'Server';
} }
@ -106,10 +106,11 @@ function composeDeviceAttributes($flight, $ring, $build, $arch, $sku, $type) {
$attrib = array( $attrib = array(
'App=WU_OS', 'App=WU_OS',
'AppVer='.$build, 'AppVer='.$build,
'AttrDataVer=120', 'AttrDataVer=134',
'BlockFeatureUpdates='.$blockUpgrades, 'BlockFeatureUpdates='.$blockUpgrades,
'BranchReadinessLevel=CB', 'BranchReadinessLevel=CB',
'CurrentBranch='.$branch, 'CurrentBranch='.$branch,
'DataExpDateEpoch_21H1='.(time()+82800),
'DataExpDateEpoch_20H1='.(time()+82800), 'DataExpDateEpoch_20H1='.(time()+82800),
'DataExpDateEpoch_19H1='.(time()+82800), 'DataExpDateEpoch_19H1='.(time()+82800),
'DataVer_RS5=2000000000', 'DataVer_RS5=2000000000',
@ -117,14 +118,12 @@ function composeDeviceAttributes($flight, $ring, $build, $arch, $sku, $type) {
'DeviceFamily='.$dvcFamily, 'DeviceFamily='.$dvcFamily,
'EKB19H2InstallCount=1', 'EKB19H2InstallCount=1',
'EKB19H2InstallTimeEpoch=1255000000', 'EKB19H2InstallTimeEpoch=1255000000',
'EKB20H2InstallCount=1',
'EKB20H2InstallTimeEpoch=1255000000',
'EKB21H1InstallCount=1',
'EKB21H1InstallTimeEpoch=1255000000',
'FlightingBranchName='.$fltBranch, 'FlightingBranchName='.$fltBranch,
'FlightContent='.$fltContent, //'FlightContent='.$fltContent,
'FlightRing='.$fltRing, 'FlightRing='.$fltRing,
'Free=32to64', 'Free=32to64',
'GStatus_CO21H2=2',
'GStatus_21H1=2',
'GStatus_20H1=2', 'GStatus_20H1=2',
'GStatus_20H1Setup=2', 'GStatus_20H1Setup=2',
'GStatus_19H1=2', 'GStatus_19H1=2',
@ -154,8 +153,13 @@ function composeDeviceAttributes($flight, $ring, $build, $arch, $sku, $type) {
'SdbVer_20H1=2000000000', 'SdbVer_20H1=2000000000',
'SdbVer_19H1=2000000000', 'SdbVer_19H1=2000000000',
'TelemetryLevel=3', 'TelemetryLevel=3',
'TimestampEpochString_21H1='.(time()-3600),
'TimestampEpochString_20H1='.(time()-3600),
'TimestampEpochString_19H1='.(time()-3600),
'UpdateManagementGroup=2', 'UpdateManagementGroup=2',
'UpdateOfferedDays=0', 'UpdateOfferedDays=0',
'UpgEx_CO21H2=Green',
'UpgEx_21H1=Green',
'UpgEx_20H1=Green', 'UpgEx_20H1=Green',
'UpgEx_19H1=Green', 'UpgEx_19H1=Green',
'UpgEx_RS5=Green', 'UpgEx_RS5=Green',
@ -189,11 +193,15 @@ function branchFromBuild($build) {
$branch = 'rs5_release'; $branch = 'rs5_release';
break; break;
case 17784:
$branch = 'rs5_release';
break;
case 18362: case 18362:
$branch = '19h1_release'; $branch = '19h1_release';
break; break;
case 18363: //18363 is a fake build based on 18362 case 18363: //a fake build based on 18362
$branch = '19h1_release'; $branch = '19h1_release';
break; break;
@ -201,11 +209,15 @@ function branchFromBuild($build) {
$branch = 'vb_release'; $branch = 'vb_release';
break; break;
case 19042: //19042 is a fake build based on 19041 case 19042: //a fake build based on 19041
$branch = 'vb_release'; $branch = 'vb_release';
break; break;
case 19043: //19043 is a fake build based on 19041 case 19043: //a fake build based on 19041
$branch = 'vb_release';
break;
case 19044: //a fake build based on 19041
$branch = 'vb_release'; $branch = 'vb_release';
break; break;
@ -213,6 +225,10 @@ function branchFromBuild($build) {
$branch = 'fe_release_10x'; $branch = 'fe_release_10x';
break; break;
case 20348:
$branch = 'fe_release';
break;
default: default:
$branch = 'rs_prerelease'; $branch = 'rs_prerelease';
break; break;
@ -297,7 +313,7 @@ function composeFetchUpdRequest($device, $encData, $arch, $flight, $ring, $build
$branch = branchFromBuild($build); $branch = branchFromBuild($build);
$mainProduct = 'Client.OS.rs2'; $mainProduct = 'Client.OS.rs2';
if($sku == 7 || $sku == 8 || $sku == 120 || $sku == 145 || $sku == 146 || $sku == 168) { if($sku == 7 || $sku == 8 || $sku == 12 || $sku == 13 || $sku == 79 || $sku == 80 || $sku == 120 || $sku == 145 || $sku == 146 || $sku == 147 || $sku == 148 || $sku == 159 || $sku == 160 || $sku == 406 || $sku == 407 || $sku == 408) {
$mainProduct = 'Server.OS'; $mainProduct = 'Server.OS';
} }
/*/ Hololens /*/ Hololens
@ -349,9 +365,10 @@ function composeFetchUpdRequest($device, $encData, $arch, $flight, $ring, $build
} }
$callerAttrib = array( $callerAttrib = array(
'Profile=AUv2',
'Acquisition=1',
'Interactive=1', 'Interactive=1',
'IsSeeker=1', 'IsSeeker=1',
'Profile=AUv2',
'SheddingAware=1', 'SheddingAware=1',
'Id=MoUpdateOrchestrator', 'Id=MoUpdateOrchestrator',
); );