Exploit database

GH-ea91ecf629103514d4b348ce44007631

jamf/cve-2020-1206-poc

GitHubNot listedPoC
Download repository ZIP

Sources for CVE-2020-1206

3 sources

Preferred order: Exploit-DB, Metasploit, then GitHub repositories by stars. Open preferred source

Repository files14

Files from this repository share one source choice. Supporting files may cover other vulnerabilities.

TestSuites/RDP/Tools/RDPToolSet/RDPToolSet.Web/Controllers/RFXEncodeController.cs

C# · 1,593 bytes
using System;
using System.Collections.Generic;
using System.Drawing;
using System.IO;
using System.Linq;
using System.Net;
using System.Web;
using System.Web.Mvc;
using System.Web.Script.Serialization;
using CodecToolSet.Core;
using CodecToolSet.Core.RFXEncode;
using RDPToolSet.Web.Models;

namespace RDPToolSet.Web.Controllers
{
   public class RFXEncodeController : CodecBaseController
   {

       public override ActionResult Index()
       {
           var rfxEncode = new RFXEncode();
           var rfxEnocdeModel = new RFXEncodeViewModel();
           var envValues = new Dictionary<string, object>
           {
               {ActionKey, rfxEncode},
               {ModelKey, rfxEnocdeModel}
           };
           SaveToSession(envValues);
           LoadFromSession();
           return View(_viewModel);
       }

        public ActionResult Encode()
        {
            dynamic obj = GetJsonObject(Request.InputStream);

            // retrieve the quant
            var quantArray = JsonHelper.RetrieveQuantsArray(obj.Params.QuantizationFactorsArray);
            _codecAction.Parameters[Constants.PARAM_NAME_QUANT_FACTORS_ARRAY] = quantArray;

            _codecAction.Parameters[Constants.PARAM_NAME_ENTROPY_ALGORITHM] = JsonHelper.CastTo<EntropyAlgorithm>(obj.Params.EntropyAlgorithm);



            // TODO: error handle
            var encodeImagePath = (string)Session[EncodedImage];
            var tile = Tile.FromFile(encodeImagePath);

            _codecAction.DoAction(tile);

            return new HttpStatusCodeResult(HttpStatusCode.OK);
        }
   }
}