diff --git a/XClipper.App/Data/helpers/AppException.cs b/XClipper.App/Data/helpers/AppException.cs index 1f0141f7..1ef73df0 100644 --- a/XClipper.App/Data/helpers/AppException.cs +++ b/XClipper.App/Data/helpers/AppException.cs @@ -162,6 +162,7 @@ private async Task SendReport(string sender, string content) .Append("&category=0"); // 0 means Desktop var client = new RestClient(); var request = new RestRequest(queryBuilder.ToString(), Method.POST); + request.AddHeaders(COMMON_HEADERS()); request.AddParameter("text/plain", content, ParameterType.RequestBody); await client.ExecuteTaskAsync(request).ConfigureAwait(false); } diff --git a/XClipper.App/Properties/AssemblyInfo.cs b/XClipper.App/Properties/AssemblyInfo.cs index 4d9fa2a8..356b5ccf 100644 --- a/XClipper.App/Properties/AssemblyInfo.cs +++ b/XClipper.App/Properties/AssemblyInfo.cs @@ -51,5 +51,5 @@ // You can specify all the values or you can default the Build and Revision Numbers // by using the '*' as shown below: // [assembly: AssemblyVersion("1.0.*")] -[assembly: AssemblyVersion("0.1.5.7")] -[assembly: AssemblyFileVersion("0.1.5.7")] +[assembly: AssemblyVersion("0.1.5.8")] +[assembly: AssemblyFileVersion("0.1.5.8")] diff --git a/XClipper.App/ViewModel/BuyViewModel.cs b/XClipper.App/ViewModel/BuyViewModel.cs index e1313d19..254ac511 100644 --- a/XClipper.App/ViewModel/BuyViewModel.cs +++ b/XClipper.App/ViewModel/BuyViewModel.cs @@ -68,7 +68,7 @@ private async void MigrationMethod() IsProgressiveWork = true; var client = new RestClient(MIGRATION_SERVER(UID, MTI, DOP.ToFormattedDate())); - var response = await client.ExecuteTaskAsync(new RestRequest(Method.POST)).ConfigureAwait(true); + var response = await client.ExecuteTaskAsync(new RestRequest(Method.POST).AddHeaders(COMMON_HEADERS())).ConfigureAwait(true); if (response.StatusCode != System.Net.HttpStatusCode.NotFound) { var obj = JObject.Parse(response.Content); @@ -121,7 +121,7 @@ private async void ActivationMethod() IsProgressiveWork = true; var client = new RestClient(ACTIVATION_SERVER(UID, EM, TI, LT.GetName())); - var response = await client.ExecuteTaskAsync(new RestRequest(Method.POST)).ConfigureAwait(true); + var response = await client.ExecuteTaskAsync(new RestRequest(Method.POST).AddHeaders(COMMON_HEADERS())).ConfigureAwait(true); try { var obj = JObject.Parse(response.Content); if (response.StatusCode == System.Net.HttpStatusCode.OK) diff --git a/XClipper.Core/Data/Extensions/RestClientExtensions.cs b/XClipper.Core/Data/Extensions/RestClientExtensions.cs new file mode 100644 index 00000000..fa05a1c8 --- /dev/null +++ b/XClipper.Core/Data/Extensions/RestClientExtensions.cs @@ -0,0 +1,22 @@ +using RestSharp; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Runtime.CompilerServices; +using System.Text; +using System.Threading.Tasks; + +namespace Components +{ + public static class RestClientExtensions + { + public static RestRequest AddHeaders(this RestRequest request, Dictionary headers) + { + foreach (var header in headers) + { + request.AddHeader(header.Key, header.Value); + } + return request; + } + } +} diff --git a/XClipper.Core/XClipper.Core.csproj b/XClipper.Core/XClipper.Core.csproj index 72c25c83..809380d2 100644 --- a/XClipper.Core/XClipper.Core.csproj +++ b/XClipper.Core/XClipper.Core.csproj @@ -55,6 +55,9 @@ + + ..\packages\RestSharp.104.4.0\lib\net4\RestSharp.dll + ..\packages\sqlite-net-sqlcipher.1.6.292\lib\netstandard1.1\SQLite-net.dll @@ -113,6 +116,7 @@ + diff --git a/XClipper.Core/packages.config b/XClipper.Core/packages.config index 5c8b9732..d1ba502f 100644 --- a/XClipper.Core/packages.config +++ b/XClipper.Core/packages.config @@ -7,6 +7,7 @@ + diff --git a/XClipper.Web/js/purchase.min.js b/XClipper.Web/js/purchase.min.js index b42453b8..b11ee5b0 100644 --- a/XClipper.Web/js/purchase.min.js +++ b/XClipper.Web/js/purchase.min.js @@ -1 +1 @@ -const _0x34210c=_0x3e8d;function _0x3e8d(_0x3dcf2e,_0x4c87a3){const _0x336ddf=_0x336d();return _0x3e8d=function(_0x3e8ddb,_0x5706d9){_0x3e8ddb=_0x3e8ddb-0x177;let _0x222fd8=_0x336ddf[_0x3e8ddb];return _0x222fd8;},_0x3e8d(_0x3dcf2e,_0x4c87a3);}(function(_0xa2e2d9,_0x3e96db){const _0x2f0c74=_0x3e8d,_0x5e8a97=_0xa2e2d9();while(!![]){try{const _0x30941f=-parseInt(_0x2f0c74(0x17d))/0x1*(-parseInt(_0x2f0c74(0x197))/0x2)+parseInt(_0x2f0c74(0x19b))/0x3*(-parseInt(_0x2f0c74(0x190))/0x4)+-parseInt(_0x2f0c74(0x1ad))/0x5+parseInt(_0x2f0c74(0x1b4))/0x6*(-parseInt(_0x2f0c74(0x19a))/0x7)+-parseInt(_0x2f0c74(0x1c6))/0x8*(parseInt(_0x2f0c74(0x1a2))/0x9)+-parseInt(_0x2f0c74(0x1c4))/0xa*(parseInt(_0x2f0c74(0x1a5))/0xb)+parseInt(_0x2f0c74(0x17f))/0xc;if(_0x30941f===_0x3e96db)break;else _0x5e8a97['push'](_0x5e8a97['shift']());}catch(_0x4ef4bc){_0x5e8a97['push'](_0x5e8a97['shift']());}}}(_0x336d,0x26ce2));const extra_tip=document[_0x34210c(0x1b0)](_0x34210c(0x188));extra_tip['addEventListener'](_0x34210c(0x1b5),_0x9589b6=>{const _0x439f5c=_0x34210c,_0x17f13e=document[_0x439f5c(0x1b0)](_0x439f5c(0x1bc)),_0x4c755a=document[_0x439f5c(0x1b0)]('purchase_emailInput');renderPremiumPaypalButton();});async function premiumPurchaseClick(){const _0x50e93a=_0x34210c;if(Number(window[_0x50e93a(0x19f)][_0x50e93a(0x18b)]<=0x258)){showDialog(_0x50e93a(0x19e),_0x50e93a(0x1a3),_0x50e93a(0x189));return;}$(_0x50e93a(0x1d0))[_0x50e93a(0x184)](''),document[_0x50e93a(0x1b0)](_0x50e93a(0x1bc))['value']='',document[_0x50e93a(0x1b0)]('purchase_emailInput')['value']='',document[_0x50e93a(0x1b0)](_0x50e93a(0x195))['innerHTML']=_0x50e93a(0x1cf),document['getElementById']('extra_tip')[_0x50e93a(0x18c)]=![],hideDefault(),renderPremiumPaypalButton(),$('#purchaseModal')['modal'](_0x50e93a(0x194));}function renderPremiumPaypalButton(){const _0x18b8df=_0x34210c;$(_0x18b8df(0x1d0))['html'](''),amount=Number(document[_0x18b8df(0x1b0)](_0x18b8df(0x18e))[_0x18b8df(0x1bd)]),extra_tip[_0x18b8df(0x18c)]===!![]&&(amount+=Number(extra_tip[_0x18b8df(0x1ca)])),showPaypal(amount,_0x18b8df(0x179));}function isUidInvalid(){const _0x564d51=_0x34210c;uidString=document[_0x564d51(0x1b0)](_0x564d51(0x1bc))['value'];var _0x875be0=/[\w\d]+\-[\w\d]+\-[\w\d]+\-[\w\d]+/g;return _0x875be0[_0x564d51(0x1d1)](uidString);}function isEmailInvalid(){const _0x49e118=_0x34210c;email=document[_0x49e118(0x1b0)]('purchase_emailInput')['value'];var _0x3c1a14=/[^@ \t\r\n]+@[^@ \t\r\n]+\.[^@ \t\r\n]+/g;return _0x3c1a14['test'](email);}function eventChangeListener(_0x348e84){const _0x51ad9e=_0x34210c;return!isUidInvalid()||!isEmailInvalid()?(_0x348e84?.[_0x51ad9e(0x1ae)](),![]):(_0x348e84?.['enable'](),!![]);}function showPaypal(_0x11e7ff,_0x4ef01f){const _0x6b0026=_0x34210c;paypal[_0x6b0026(0x1a6)]({'style':{'layout':_0x6b0026(0x191)},'onInit':function(_0x21c6c5,_0x181ccb){const _0x1063af=_0x6b0026;document[_0x1063af(0x1b0)](_0x1063af(0x1bc))[_0x1063af(0x198)]=function(){eventChangeListener(_0x181ccb);},document[_0x1063af(0x1b0)](_0x1063af(0x1a9))[_0x1063af(0x198)]=function(){eventChangeListener(_0x181ccb);};const _0x8fd9a6=document[_0x1063af(0x1c3)]('paypal-button-tagline');console[_0x1063af(0x185)](_0x8fd9a6),eventChangeListener(_0x181ccb);},'onClick':function(){const _0x4feeb2=_0x6b0026,_0x493249=document[_0x4feeb2(0x1b0)](_0x4feeb2(0x1bc))['value'][_0x4feeb2(0x1a7)](),_0x15b84a=document[_0x4feeb2(0x1b0)](_0x4feeb2(0x1a9))[_0x4feeb2(0x1ca)]['trim']();if(_0x493249[_0x4feeb2(0x1c7)]==0x0||_0x15b84a['length']==0x0)showErrorToast(_0x4feeb2(0x1c5),0xfa0);else{if(!isUidInvalid())showErrorToast(_0x4feeb2(0x1be),0xfa0);else!isEmailInvalid()&&showErrorToast('Email\x20is\x20not\x20in\x20the\x20correct\x20format.',0xfa0);}console[_0x4feeb2(0x185)](_0x4feeb2(0x1c2));},'createOrder':async function(_0x129b37,_0x36c93e){const _0x5e925c=_0x6b0026,_0x44be2e=document[_0x5e925c(0x1b0)](_0x5e925c(0x1bc))['value'],_0x242ae9=await fetch('https://kaustubh-patange.herokuapp.com/xclipper/duplicate?uid='+_0x44be2e);return _0x242ae9[_0x5e925c(0x183)]>0x190?(showErrorToast(_0x5e925c(0x1cd),0xfa0),null):_0x36c93e[_0x5e925c(0x193)][_0x5e925c(0x199)]({'application_context':{'shipping_preference':'NO_SHIPPING'},'purchase_units':[{'amount':{'value':_0x11e7ff}}]});},'onApprove':function(_0x12d9da,_0x32e9ea){const _0x16ceb4=_0x6b0026;return _0x32e9ea[_0x16ceb4(0x193)][_0x16ceb4(0x18a)]()[_0x16ceb4(0x192)](function(_0x455eff){const _0x3d0583=_0x16ceb4;if(_0x455eff[_0x3d0583(0x1af)]===_0x3d0583(0x1ab))return _0x32e9ea[_0x3d0583(0x1b9)]();else verifyPayment(_0x455eff,_0x4ef01f);});},'onCancel':function(_0x1368fd,_0x1ef386){hideDefault();},'onError':function(_0x5e9a70){const _0x4e7ce2=_0x6b0026;_0x5e9a70!=_0x4e7ce2(0x1a8)&&showErrorToast(_0x5e9a70);}})[_0x6b0026(0x17e)](_0x6b0026(0x1d0));}async function verifyPayment(_0x180561,_0x27581a){const _0x569282=_0x34210c,_0xaa6626=_0x569282(0x182)+_0x180561[_0x569282(0x17c)][0x0]['payments']['captures'][0x0]['id']+_0x569282(0x178)+_0x27581a+'&email='+document[_0x569282(0x1b0)](_0x569282(0x1a9))[_0x569282(0x1ca)]+_0x569282(0x180)+document['getElementById'](_0x569282(0x1bc))[_0x569282(0x1ca)],_0x3ccf68={'url':_0xaa6626,'method':'POST'};try{const _0x391fd7=await promisifiedRequest(_0x3ccf68),_0x22ed0d=JSON[_0x569282(0x1ce)](_0x391fd7);document[_0x569282(0x1b0)](_0x569282(0x1b2))['style'][_0x569282(0x1ac)]=_0x569282(0x186),_0x22ed0d[_0x569282(0x183)]==='success'||_0x22ed0d['status']===_0x569282(0x1c8)?(document[_0x569282(0x1b0)](_0x569282(0x1cc))[_0x569282(0x1ba)][_0x569282(0x1ac)]=_0x569282(0x177),$(_0x569282(0x1a1))[_0x569282(0x1c9)](_0x569282(0x1aa)),showModalDialog(_0x569282(0x1c0),_0x569282(0x181),'Alright',_0x569282(0x1cb))):showErrorMessage(_0x22ed0d[_0x569282(0x1b6)]);}catch{showErrorMessage(_0x569282(0x1b1));}}function hideDefault(){const _0xc3e3bc=_0x34210c;document[_0xc3e3bc(0x1b0)](_0xc3e3bc(0x17a))[_0xc3e3bc(0x1ba)][_0xc3e3bc(0x1ac)]=_0xc3e3bc(0x177),document[_0xc3e3bc(0x1b0)](_0xc3e3bc(0x1b2))[_0xc3e3bc(0x1ba)][_0xc3e3bc(0x1ac)]=_0xc3e3bc(0x186),document['getElementById']('modal-content-success')[_0xc3e3bc(0x1ba)]['display']='none',document['getElementById'](_0xc3e3bc(0x1c1))[_0xc3e3bc(0x1ba)][_0xc3e3bc(0x1ac)]=_0xc3e3bc(0x186);}function showErrorMessage(_0x120d1e){const _0x2f4a3e=_0x34210c;document[_0x2f4a3e(0x1b0)](_0x2f4a3e(0x1b2))[_0x2f4a3e(0x1ba)][_0x2f4a3e(0x1ac)]=_0x2f4a3e(0x186),document[_0x2f4a3e(0x1b0)](_0x2f4a3e(0x1c1))['style'][_0x2f4a3e(0x1ac)]=_0x2f4a3e(0x177),document[_0x2f4a3e(0x1b0)](_0x2f4a3e(0x187))[_0x2f4a3e(0x1a4)]=''+_0x120d1e;}function _0x336d(){const _0x22b4d6=['getElementById','Developer\x20Error','modal-progress','dialog-title','402ZwtVPx','change','message','dialog-content','content-type','restart','style','url','uidInput','innerText','Unique\x20ID\x20is\x20not\x20in\x20the\x20correct\x20format.','#dialog-modal','Purchase\x20Completed','modal-content-failed','Clicked','getElementsByClassName','1974180VCfaWO','Email\x20or\x20Unique\x20ID\x20cannot\x20be\x20empty.','26088heITmA','length','exist','modal','value','XClipper.Web/raw/premium_unlocked.json','modal-content-success','The\x20Unique\x20Id\x20already\x20exist\x20in\x20database.','parse','Premium\x20Purchase','#render-payment-button','test','block','&type=','Premium','modal-payment','toast','purchase_units','6555aluuoQ','render','11067468lbNBIn','&uid=','Restart\x20the\x20XClipper\x20application\x20on\x20Windows\x20to\x20activate\x20the\x20license.','https://kaustubh-patange.herokuapp.com/xclipper/license?orderId=','status','html','log','none','modal-content-text-subtitle','extra_tip','Close','capture','width','checked','readyState','premium-card-amount','Authorization','56pBpPlP','horizontal','then','order','show','purchaseModel-title','setRequestHeader','68RVNajB','oninput','create','28553fXjUVr','50763bQFFwJ','send','method','Unsupported\x20device','screen','dialog-button','#purchaseModal','747DBGsUQ','Looks\x20like\x20you\x20are\x20on\x20a\x20mobile\x20device,\x20better\x20switch\x20to\x20desktop\x20to\x20continue\x20the\x20purchase!','innerHTML','11gmmXzp','Buttons','trim','Error:\x20Expected\x20an\x20order\x20id\x20to\x20be\x20passed','purchase_emailInput','hide','INSTRUMENT_DECLINED','display','39725fiepoA','disable','error'];_0x336d=function(){return _0x22b4d6;};return _0x336d();}const promisifiedRequest=(_0x1880e0,_0x45cbdb=null)=>{return new Promise((_0x37b636,_0x795239)=>{const _0x2478a5=_0x3e8d,_0x3cae40=new XMLHttpRequest();_0x3cae40['onreadystatechange']=function(){const _0x1d4fd8=_0x3e8d;if(_0x3cae40[_0x1d4fd8(0x18d)]==0x4)switch(_0x3cae40[_0x1d4fd8(0x183)]){case 0xc8:case 0x190:case 0x191:case 0x193:case 0x194:_0x37b636(_0x3cae40['responseText']);break;}},_0x3cae40['open'](_0x1880e0[_0x2478a5(0x19d)],_0x1880e0[_0x2478a5(0x1bb)],!![]);if(_0x1880e0['hasOwnProperty']('content_type'))_0x3cae40[_0x2478a5(0x196)](_0x2478a5(0x1b8),_0x1880e0['content_type']);if(_0x1880e0['hasOwnProperty'](_0x2478a5(0x18f)))_0x3cae40[_0x2478a5(0x196)]('Authorization',_0x1880e0['Authorization']);_0x3cae40[_0x2478a5(0x19c)](_0x45cbdb);});};function showErrorToast(_0x2cafb0,_0x1d0251=0x9c4){const _0x15a4d9=_0x34210c,_0x508870={'style':{'main':{'background':'#ff5733','font-family':'roboto\x20mono'}},'settings':{'duration':_0x1d0251}};iqwerty[_0x15a4d9(0x17b)][_0x15a4d9(0x17b)](_0x2cafb0,_0x508870);}function showDialog(_0x2628db,_0x5628bb,_0x2ca34a){const _0x5ac1eb=_0x34210c;document[_0x5ac1eb(0x1b0)](_0x5ac1eb(0x1b3))[_0x5ac1eb(0x1a4)]=_0x2628db,document[_0x5ac1eb(0x1b0)](_0x5ac1eb(0x1b7))[_0x5ac1eb(0x1a4)]=_0x5628bb,document[_0x5ac1eb(0x1b0)](_0x5ac1eb(0x1a0))[_0x5ac1eb(0x1a4)]=_0x2ca34a,$(_0x5ac1eb(0x1bf))['modal'](_0x5ac1eb(0x194));} \ No newline at end of file +const _0xed8347=_0x3696;(function(_0x8ab9e3,_0x18f075){const _0x3039a0=_0x3696,_0x250fc6=_0x8ab9e3();while(!![]){try{const _0x5c4b27=parseInt(_0x3039a0(0xcd))/0x1*(parseInt(_0x3039a0(0x9d))/0x2)+-parseInt(_0x3039a0(0xcc))/0x3*(-parseInt(_0x3039a0(0xca))/0x4)+parseInt(_0x3039a0(0xe7))/0x5*(-parseInt(_0x3039a0(0xae))/0x6)+parseInt(_0x3039a0(0xe4))/0x7*(-parseInt(_0x3039a0(0xd3))/0x8)+-parseInt(_0x3039a0(0xb8))/0x9*(-parseInt(_0x3039a0(0xa5))/0xa)+parseInt(_0x3039a0(0xf1))/0xb*(-parseInt(_0x3039a0(0xdb))/0xc)+parseInt(_0x3039a0(0xa7))/0xd*(-parseInt(_0x3039a0(0xda))/0xe);if(_0x5c4b27===_0x18f075)break;else _0x250fc6['push'](_0x250fc6['shift']());}catch(_0x567e6c){_0x250fc6['push'](_0x250fc6['shift']());}}}(_0x376b,0xdeb96));const extra_tip=document['getElementById'](_0xed8347(0x9c));function _0x3696(_0x1825b9,_0x5b34e2){const _0x376b1c=_0x376b();return _0x3696=function(_0x369632,_0x55cec5){_0x369632=_0x369632-0x96;let _0x9b43d6=_0x376b1c[_0x369632];return _0x9b43d6;},_0x3696(_0x1825b9,_0x5b34e2);}extra_tip[_0xed8347(0xbe)](_0xed8347(0x9e),_0xe6e7f6=>{const _0xdda3ea=_0xed8347,_0x312a32=document[_0xdda3ea(0xa2)](_0xdda3ea(0xad)),_0x32ce97=document['getElementById'](_0xdda3ea(0xf4));renderPremiumPaypalButton();});async function premiumPurchaseClick(){const _0x221811=_0xed8347;if(Number(window['screen'][_0x221811(0xc9)]<=0x258)){showDialog(_0x221811(0xa0),_0x221811(0xb3),_0x221811(0xb4));return;}$(_0x221811(0xdf))[_0x221811(0xea)](''),document['getElementById'](_0x221811(0xad))[_0x221811(0xe1)]='',document[_0x221811(0xa2)](_0x221811(0xf4))[_0x221811(0xe1)]='',document['getElementById'](_0x221811(0xe8))[_0x221811(0xd7)]=_0x221811(0xf3),document[_0x221811(0xa2)]('extra_tip')['checked']=![],hideDefault(),renderPremiumPaypalButton(),$(_0x221811(0xc0))['modal'](_0x221811(0xc3));}function renderPremiumPaypalButton(){const _0x100fd6=_0xed8347;$('#render-payment-button')['html'](''),amount=Number(document[_0x100fd6(0xa2)](_0x100fd6(0xd6))['innerText']),extra_tip[_0x100fd6(0xb9)]===!![]&&(amount+=Number(extra_tip[_0x100fd6(0xe1)])),showPaypal(amount,'Premium');}function isUidInvalid(){const _0x3ef888=_0xed8347;uidString=document[_0x3ef888(0xa2)](_0x3ef888(0xad))[_0x3ef888(0xe1)];var _0x293a1e=/[\w\d]+\-[\w\d]+\-[\w\d]+\-[\w\d]+/g;return _0x293a1e['test'](uidString);}function isEmailInvalid(){const _0x2c1c84=_0xed8347;email=document[_0x2c1c84(0xa2)](_0x2c1c84(0xf4))[_0x2c1c84(0xe1)];var _0x418378=/[^@ \t\r\n]+@[^@ \t\r\n]+\.[^@ \t\r\n]+/g;return _0x418378['test'](email);}function eventChangeListener(_0x1caccd){return!isUidInvalid()||!isEmailInvalid()?(_0x1caccd?.['disable'](),![]):(_0x1caccd?.['enable'](),!![]);}function showPaypal(_0x43d278,_0x2fb083){const _0x35f85b=_0xed8347;paypal[_0x35f85b(0xd9)]({'style':{'layout':_0x35f85b(0xe0)},'onInit':function(_0x442ffe,_0x343552){const _0x10b62c=_0x35f85b;document[_0x10b62c(0xa2)](_0x10b62c(0xad))['oninput']=function(){eventChangeListener(_0x343552);},document['getElementById'](_0x10b62c(0xf4))[_0x10b62c(0xbc)]=function(){eventChangeListener(_0x343552);};const _0x6d33de=document[_0x10b62c(0xc2)](_0x10b62c(0x9b));console[_0x10b62c(0xc8)](_0x6d33de),eventChangeListener(_0x343552);},'onClick':function(){const _0x5c56d9=_0x35f85b,_0x310bba=document[_0x5c56d9(0xa2)](_0x5c56d9(0xad))['value'][_0x5c56d9(0xce)](),_0x361d63=document['getElementById'](_0x5c56d9(0xf4))['value'][_0x5c56d9(0xce)]();if(_0x310bba[_0x5c56d9(0xe3)]==0x0||_0x361d63[_0x5c56d9(0xe3)]==0x0)showErrorToast(_0x5c56d9(0xa6),0xfa0);else{if(!isUidInvalid())showErrorToast('Unique\x20ID\x20is\x20not\x20in\x20the\x20correct\x20format.',0xfa0);else!isEmailInvalid()&&showErrorToast(_0x5c56d9(0xe9),0xfa0);}console[_0x5c56d9(0xc8)](_0x5c56d9(0xf0));},'createOrder':async function(_0xe91878,_0x10b697){const _0x442d3a=_0x35f85b,_0x56768a=document[_0x442d3a(0xa2)](_0x442d3a(0xad))['value'],_0x4d6b83=await fetch(_0x442d3a(0x97)+_0x56768a);return _0x4d6b83[_0x442d3a(0xf6)]>0x190?(showErrorToast(_0x442d3a(0xb7),0xfa0),null):_0x10b697[_0x442d3a(0xa9)][_0x442d3a(0xe2)]({'application_context':{'shipping_preference':_0x442d3a(0xc1)},'purchase_units':[{'amount':{'value':_0x43d278}}]});},'onApprove':function(_0x3acbc4,_0x5648cd){const _0x10d37b=_0x35f85b;return _0x5648cd[_0x10d37b(0xa9)][_0x10d37b(0xbf)]()[_0x10d37b(0xdc)](function(_0x510a0f){const _0x2603f0=_0x10d37b;if(_0x510a0f['error']===_0x2603f0(0xc6))return _0x5648cd[_0x2603f0(0xd4)]();else verifyPayment(_0x510a0f,_0x2fb083);});},'onCancel':function(_0x59b51c,_0x7264d6){hideDefault();},'onError':function(_0x1c72ee){const _0x472d62=_0x35f85b;_0x1c72ee!=_0x472d62(0x96)&&showErrorToast(_0x1c72ee);}})[_0x35f85b(0xc5)](_0x35f85b(0xdf));}async function verifyPayment(_0x54496e,_0x1d43be){const _0x2ad23e=_0xed8347,_0x407b70=_0x2ad23e(0xaf)+_0x54496e[_0x2ad23e(0xcf)][0x0][_0x2ad23e(0xf5)]['captures'][0x0]['id']+_0x2ad23e(0xb5)+_0x1d43be+'&email='+document['getElementById'](_0x2ad23e(0xf4))[_0x2ad23e(0xe1)]+_0x2ad23e(0xdd)+document[_0x2ad23e(0xa2)](_0x2ad23e(0xad))[_0x2ad23e(0xe1)],_0x3668a0={'url':_0x407b70,'method':'POST'};try{const _0x53a477=await promisifiedRequest(_0x3668a0),_0x16f265=JSON[_0x2ad23e(0xa4)](_0x53a477);document[_0x2ad23e(0xa2)](_0x2ad23e(0xe5))['style'][_0x2ad23e(0xbb)]=_0x2ad23e(0xbd),_0x16f265[_0x2ad23e(0xf6)]===_0x2ad23e(0xec)||_0x16f265[_0x2ad23e(0xf6)]===_0x2ad23e(0xb2)?(document[_0x2ad23e(0xa2)]('modal-content-success')[_0x2ad23e(0xf7)]['display']=_0x2ad23e(0xc4),$('#purchaseModal')['modal'](_0x2ad23e(0xe6)),showModalDialog(_0x2ad23e(0xd5),_0x2ad23e(0xa1),_0x2ad23e(0xaa),'XClipper.Web/raw/premium_unlocked.json')):showErrorMessage(_0x16f265[_0x2ad23e(0xb1)]);}catch{showErrorMessage(_0x2ad23e(0xd8));}}function hideDefault(){const _0x919771=_0xed8347;document[_0x919771(0xa2)](_0x919771(0xac))[_0x919771(0xf7)][_0x919771(0xbb)]=_0x919771(0xc4),document[_0x919771(0xa2)](_0x919771(0xe5))['style'][_0x919771(0xbb)]=_0x919771(0xbd),document[_0x919771(0xa2)](_0x919771(0xeb))[_0x919771(0xf7)][_0x919771(0xbb)]='none',document[_0x919771(0xa2)]('modal-content-failed')[_0x919771(0xf7)][_0x919771(0xbb)]=_0x919771(0xbd);}function showErrorMessage(_0x14dfdf){const _0x4b1c58=_0xed8347;document[_0x4b1c58(0xa2)]('modal-progress')[_0x4b1c58(0xf7)]['display']=_0x4b1c58(0xbd),document[_0x4b1c58(0xa2)](_0x4b1c58(0xc7))['style'][_0x4b1c58(0xbb)]=_0x4b1c58(0xc4),document[_0x4b1c58(0xa2)](_0x4b1c58(0xb6))[_0x4b1c58(0xd7)]=''+_0x14dfdf;}const promisifiedRequest=(_0x5bb189,_0xa95a6b=null)=>{return new Promise((_0x14c7e6,_0x501a07)=>{const _0x365cc5=_0x3696,_0x1b4767=new XMLHttpRequest();_0x1b4767[_0x365cc5(0xf8)]=function(){const _0x34cb5c=_0x365cc5;if(_0x1b4767[_0x34cb5c(0xcb)]==0x4)switch(_0x1b4767[_0x34cb5c(0xf6)]){case 0xc8:case 0x190:case 0x191:case 0x193:case 0x194:_0x14c7e6(_0x1b4767[_0x34cb5c(0x99)]);break;}},_0x1b4767[_0x365cc5(0xed)](_0x5bb189[_0x365cc5(0xd2)],_0x5bb189[_0x365cc5(0xab)],!![]);if(_0x5bb189[_0x365cc5(0xba)]('content_type'))_0x1b4767[_0x365cc5(0xa3)](_0x365cc5(0xde),_0x5bb189[_0x365cc5(0xee)]);if(_0x5bb189[_0x365cc5(0xba)]('Authorization'))_0x1b4767['setRequestHeader']('Authorization',_0x5bb189[_0x365cc5(0x9f)]);_0x1b4767[_0x365cc5(0xa8)](_0xa95a6b);});};function showErrorToast(_0x3a4817,_0x2ed7c4=0x9c4){const _0x2ad781=_0xed8347,_0x12c9a2={'style':{'main':{'background':_0x2ad781(0x9a),'font-family':_0x2ad781(0xd0)}},'settings':{'duration':_0x2ed7c4}};iqwerty[_0x2ad781(0x98)][_0x2ad781(0x98)](_0x3a4817,_0x12c9a2);}function _0x376b(){const _0x51d399=['send','order','Alright','url','modal-payment','uidInput','3690ImrCiO','https://api.kaustubhpatange.com/xclipper/license?orderId=','modal','message','exist','Looks\x20like\x20you\x20are\x20on\x20a\x20mobile\x20device,\x20better\x20switch\x20to\x20desktop\x20to\x20continue\x20the\x20purchase!','Close','&type=','modal-content-text-subtitle','The\x20Unique\x20Id\x20already\x20exist\x20in\x20database.','32013fLmRxT','checked','hasOwnProperty','display','oninput','none','addEventListener','capture','#purchaseModal','NO_SHIPPING','getElementsByClassName','show','block','render','INSTRUMENT_DECLINED','modal-content-failed','log','width','3764hMtebs','readyState','15pELOip','1sOgdzm','trim','purchase_units','roboto\x20mono','dialog-title','method','8Wztgbv','restart','Purchase\x20Completed','premium-card-amount','innerHTML','Developer\x20Error','Buttons','1498txGbxW','318720iMSShH','then','&uid=','content-type','#render-payment-button','horizontal','value','create','length','208061YZUBme','modal-progress','hide','2045UOebWF','purchaseModel-title','Email\x20is\x20not\x20in\x20the\x20correct\x20format.','html','modal-content-success','success','open','content_type','dialog-button','Clicked','11QFcxCA','#dialog-modal','Premium\x20Purchase','purchase_emailInput','payments','status','style','onreadystatechange','Error:\x20Expected\x20an\x20order\x20id\x20to\x20be\x20passed','https://api.kaustubhpatange.com/xclipper/duplicate?uid=','toast','responseText','#ff5733','paypal-button-tagline','extra_tip','373686MfaKFC','change','Authorization','Unsupported\x20device','Restart\x20the\x20XClipper\x20application\x20on\x20Windows\x20to\x20activate\x20the\x20license.','getElementById','setRequestHeader','parse','3070yUxhgx','Email\x20or\x20Unique\x20ID\x20cannot\x20be\x20empty.','7709OukkAL'];_0x376b=function(){return _0x51d399;};return _0x376b();}function showDialog(_0x14e66b,_0x1638b6,_0x31e218){const _0x282d6c=_0xed8347;document['getElementById'](_0x282d6c(0xd1))['innerHTML']=_0x14e66b,document['getElementById']('dialog-content')[_0x282d6c(0xd7)]=_0x1638b6,document[_0x282d6c(0xa2)](_0x282d6c(0xef))['innerHTML']=_0x31e218,$(_0x282d6c(0xf2))[_0x282d6c(0xb0)]('show');} \ No newline at end of file diff --git a/docs/wiki b/docs/wiki index f78dea8b..b95f7ef1 160000 --- a/docs/wiki +++ b/docs/wiki @@ -1 +1 @@ -Subproject commit f78dea8be4cbf9592ec56226edcdcb11c143d659 +Subproject commit b95f7ef14cddda9b94f04cb0bd21550081267496 diff --git a/scripts/changes.txt b/scripts/changes.txt index 989c7d08..9cced84f 100644 --- a/scripts/changes.txt +++ b/scripts/changes.txt @@ -1,6 +1,4 @@ ## What's new in version v0.1.x.x? -- Added: "Tools" section in Firebase Configuration window where user can export, import & delete all the data on Firebase. -- Improved: Proper message when activating license fails. -- Fixed: Incorrect exception reporting data handling. \ No newline at end of file +- Fixed: Licensing issues. \ No newline at end of file diff --git a/scripts/csproj.tar.gz b/scripts/csproj.tar.gz index afcf65e4..b746789e 100644 Binary files a/scripts/csproj.tar.gz and b/scripts/csproj.tar.gz differ