Posts

Encoding PHP array to JSON, how to encode square brackets [] and deep nested JSON

Deeply nested and squared brackets in JSON To make square brackets in JSON, which is basically array in JSON you need to use the  array operator twice, nested. So make it look like this. write some PHP array(array('something'.... $data = json_encode( array ( 'list' => array ( array ( 'commerce_price_aud' => array (.... Here's another example of deeply nested JSON with square brackets. $options = array ( 'name' => 'MySystem' , 'state' => 'INVENTORY' , 'lifeCycleState' => 'INVENTORY' , 'type' => 'My system Type' , 'gateway' => array('serialNumber' => '1234', 'creationDate' => '12345678' ), 'subscription' => array('identifier' => '1234', 'operator' => '12345678' ), 'labels' => array('labege'), 'applica...

Can You Disable Caching on CSS style Sheets? A True Hack to Stop Caching.

Image
Can We Prevent CSS Caching? Can we disable Caching of CSS pages? Can we Force a browser to re-read the CSS everytime? Those Are The Questions that broke the internet, combined with the death of Grumpy Cat, whom we could never save, not with the best in veterinary medicine. Nothing can bring her back, not even cloning or cryogenic treatments. As for CSS, we could never prevent caching. If you are a web developer, you need to refresh you pages a lot. Unfortunately, your styles sheets will never change, because your stupid browser, whether it be Chrome, Firefox, internet explorer or Edge will happily save a copy of your old CSS and keep it, and use it to render your pages.   The other unfortunate effect is that the public, i.e. your viewers and customers browsers will hang onto an old version of stylesheet.    Can we solve this? Is there some way to prevent CSS caching? Is there some magical tag that you can add to your HTML to prevent caching? The answer is NO,...

Ellie Mae Encompass - You have files that need to be attached [how to remove them]

Image
Encompass pop up dialog says " You have files that need to be attached" You have files that need to be attached Ellie Mae Encompass, Amurika's greatest home loan automation application. Symptoms for this case include logging into Encompass and getting messages that there are Documents that need to be attached, or the Background Attaching dialog box is backed up and there are consecutive failed conversions. It does not matter how many times you try to attach them to the efolder, they will never get uploaded. It will not help to restart your computer or to clear out the UAC cache.  How to fix:  Select No, and they will be deleted permanently.  Or clear out the files manually, as we describe below... Why does this happen? Because your PDF's are scaled too big. They may exceeed the 11x17 page size limit.  They may have been poorman scanned from an IOS device such as iPhone, where your borrower just took a picture of the document, and then converted it t...

Windows Update Hall of Shame

The Windows Update Hall of Shame Occasionally, Windows updates can be really bad and really screw up your computers. Here's my list of the worst offenders.  These are only bad because they really screw up when Sophos Antivirus is installed.  Some of these are showstoppers for Microsoft Exchange. KB4493472 This update can really interfere with Sophos antivirus. See the related story.   https://community.sophos.com/products/endpoint-security-control/f/sophos-endpoint-software/112101/sav-service-hangs-after-installing-kb4493472   If you have Windows 7, or Windows Server 2008, expect real trouble if you allow this one. KB4499164 Once again, more issues caused by an update rollup. Causes Sophos Antivirus protected machines to hang and freeze.    It appears that once again there are conflicts with Sophos and the most recent (MAY) patch Tuesday from Microsoft.  www.theregister.co.uk/.../   "Its advice on what to do is pretty blunt: uninst...

Unbricking and Recovering A Western Digital My Book Live World Edition

Image
How to Recover, Rebuild and Unbrick Your Western Digital My Book Live When you Mybook live is just showing red light in front, or the world edition shows just some steady white lights in front, you know it's really bad.  You can open it up, find the J8 solder pads on the board, and then solder on some header pins.  Connect those pins to a Prolific USB to Serial port converter. Just connect Grnd, URX and UTX, and then start it up. The Live edition has an onboard JTAG and UART port. Until now I don't know the pinout of the JTAG so be warned to overwrite data in the NAND. The Pinout of the UART Port "J8" is as follows: (your J8 port may not look like this at all, but it may just look like a 2x2 pin pad with a white square around it. Pin 1 = +3.3V Pin 2 = URX Pin 3 = UTX Pin 4 = GND Warning:  do not connect directly to a serial Port, you will need a ttl level shifter like the "Max233" or "FT232R". Otherwise you risk to break the hardware...

Download Java JRE Version 7 JRE7

How to Get Java JRE Version 7 Here's where you can get it. From here you can get JRE 7u80 and JDK 7u80 for those old legacy apps that don't work on Java 8. https://www.oracle.com/technetwork/java/javase/downloads/java-archive-downloads-javase7-521261.html Of course you need to logon to Oracle first. https://login.oracle.com/mysso/signon.jsp https://www.oracle.com/technetwork/java/javase/downloads/java-archive-downloads-javase7-521261.html Brought to You By This Tech Tidbit was brought to you by your Java Pros at  Eleven Dimensions Computer Technologies . See the new 11D website at: https://www.elevendimensions.com/ See Our Partner Websites: Bare Wire Networks:      http://www.barewirenetworks.com CTI Solutions:    http://www.cti-solutions.com Many Thanks to Our Partner companies

Configure Remote Desktop Services Licensing on Windows Server 2012

My Cheat Sheet for Installing a Terminal Services License Server Note: This applies to Windows Server 2012 and Server 2012R2.  Before you do this, install a few Server Roles: Remote Desktop Services ( 2 of 6 Installed)     Remote Desktop Licensing     Remote Desktop Session Host Then use the Licescing Wizard to add your licenses in the "Remote Desktop Licensing Manager". Add your CALS and your what not, and Activate your server.  Use a Campus Agreement to activate some fake CALS, almost any 7 digit number starting with 6 will work. Configuring the License Server on a RD Session Hosts After the RDS License Server is activated and running, you can reconfigure RD Session Host to obtain licenses from this server. You can select the license type and specify the name of the license server using PowerShell or GPO. To select the license type to be used, run this command: $obj = gwmi -namespace "Root/CIMV2/TerminalServices" Win32_TerminalServiceS...

Remove the Powered by Shopify slogan from a shopify website

Edit your theme's language settings Desktop   iPhone   Android From your Shopify  admin , go to  Online Store  >  Themes . Find the theme that you want to edit, and then click  Actions  >  Edit languages . In the  Filter translations  box, type "powered". In the  Powered by Shopify  box, type a single space  . The faded placeholder text in the box will disappear. You can repeat these steps for the  Powered by Shopify HTML  box, which appears on your store's "Opening soon" page if your store is password-protected. Click  Save . Edit footer.liquid Desktop   iPhone   Android From your Shopify admin, go to  Online Store  >  Themes . Find the theme you want to edit, and then click  Actions  >  Edit code . In the  Sections  folder, open the  footer.liquid  file. Use  ctrl  ...

Recover Your Files From A Ransomware Attack Without Paying Anybody

Image
Don't Pay The Ransom No More Ransomware https://www.nomoreransom.org/en/index.html Crypto Sheriff https://www.nomoreransom.org/crypto-sheriff.php?lang=en Watchpoint Data https://www.watchpointdata.com/ransomware-decryptors/ Scan A Suspicious File https://www.virustotal.com/#/home/upload Decrypting Excel Files https://www.blackhillsinfosec.com/crack-passwords-password-protected-ms-office-documents/?fbclid=IwAR1IU2RXzvcGZuX-ji8dg2-5nvNorTLCNH1bPUzGIt0lVfZfrfwpz3XJfMM Cracking Microsoft Office (97-03, 2007, 2010, 2013) password hashes with Hashcat http://pentestcorner.com/cracking-microsoft-office-97-03-2007-2010-2013-password-hashes-with-hashcat/ Exploit Database https://www.exploit-db.com/exploits/37977 Muhstik Ransomware Passwords Blog Post A victim fights back and hacks the hackers back, and produces recovery keys for all of the victims. Read more here . The STOP Ransomware Decryptor is now Free Get the Emsisoft Decryptor for STOP Djvu her...

Sending JSON via POST in PHP and CURL usage

Sometimes, you’ll come across web services and APIs that will require you to send JSON via a POST request. The php code that you need: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 <?php //API Url $url = 'http://example.com/api/JSON/create' ; //Initiate cURL. $ch = curl_init ( $url ); //The JSON data. $jsonData = array ( 'username' => 'MyUsername' , 'password' => 'MyPassword' ); //Encode the array into JSON. $jsonDataEncoded = json_encode ( $jsonData ); //Tell cURL that we want to send a POST request. curl_setopt ( $ch , CURLOPT_POST, 1 ); //Attach our encoded JSON string to the POST fields. curl_setopt ( $ch , CURLOPT_POSTFIELDS, $jsonDataEncoded ); //Set the content type to application/json curl_setopt ( $ch , CURLOPT_HTTPHEADER, array ( 'Content-Type: application/json' )); //Execute the request $result = curl_exec ( $ch ); Step by step explanation of t...

Remove and Replace non-alphanumeric Characters from Form Inputs with regex

Remove and Clean up Form inputs on POST and GET For your contact us forms, you do not want bad people to inject malware into your email, so you need to scrub and slug the posts with regex to remove any html code, and non-alphas that can be used to do nasty things to end users. Shared on GIST Example: (on ssh console) $ php slug.php <HELLO@HELLO.COM> DIRTY:<Joe_Johnson_1234@gmail.com><?> CLEAN:joe_johnson_1234@gmail.com DIRTY:Hello Mr. O'Leary, I am calling to ask your help with releasing $10000<br/> in lost cash from nigeria. Click Here: <a href="http://www.getavirus.com">Free Virus</a> You gotta "trust" \'me\' CLEAN:hello mr. o-leary, i am calling to ask your help with releasing $10000br in lost cash from nigeria. click here a href-httpwww.getavirus.com-free virusa you gotta -trust- -me

How it works: The PFC8574T I2C 8 Bit Adapter with the Vishay 20x4 LCD

Image
Using the I2C 4 line LCD https://www.rhydolabz.com/wiki/?p=16424 There is a section on the I2C LCD Backpack. The PFC8574T I2C to 8 bit IO adapter backpack onto Vishay LCD-020N004L PFD8574  ------------------->    20x4 LCD Header Strip   (4)  D0                          4  Rs   H/L Register Select (5)  D1                          5  R/W  H/L Read/write  (6)  D2                          6  E    H/L Enable      (7)  D3                                    --NC--        (9)  D4                          11 ...