Linux unitednationsplay.com 3.10.0-1160.45.1.el7.x86_64 #1 SMP Wed Oct 13 17:20:51 UTC 2021 x86_64
nginx/1.20.1
Server IP : 188.130.139.92 & Your IP : 216.73.216.44
Domains :
Cant Read [ /etc/named.conf ]
User : web
Terminal
Auto Root
Create File
Create Folder
Localroot Suggester
Backdoor Destroyer
Readme
/
home /
www /
3 /
league /
glide /
docs /
0.3 /
config /
Delete
Unzip
Name
Size
Permission
Date
Action
base-url.md
1005
B
-rw-r--r--
2020-11-05 09:00
basic-usage.md
1.47
KB
-rw-r--r--
2020-11-05 09:00
image-driver.md
406
B
-rw-r--r--
2020-11-05 09:00
max-image-size.md
621
B
-rw-r--r--
2020-11-05 09:00
secure-images.md
1.5
KB
-rw-r--r--
2020-11-05 09:00
source-and-cache.md
1.79
KB
-rw-r--r--
2020-11-05 09:00
the-server.md
2.03
KB
-rw-r--r--
2020-11-05 09:00
Save
Rename
--- layout: default title: Secure images --- # Secure images Add additional security to your Glide image server with HTTP signatures. By signing each request with a private key, no alterations can be made to the URL parameters. <p class="message-notice">It is highly recommended that you use secure URLs in production environments.</p> ## Configuration Start by configuring the Glide server to validate each request before you output the image. In the event that the validation fails, Glide will throw an `SignatureException` exception. ~~~ php <?php use League\Glide\Http\SignatureFactory; use League\Glide\Http\SignatureException; use Symfony\Component\HttpFoundation\Request; // Create request object $request = Request::createFromGlobals(); // Validate HTTP signature try { SignatureFactory::create('your-sign-key')->validateRequest($request); } catch (SignatureException $e) { // Handle error } ~~~ ## Generating secure URLs Next, generate a signature for each image request you make. Glide comes with a URL builder to make this process easy. Be sure to use the same signing key you configured earlier. ~~~ php <?php use League\Glide\Http\UrlBuilderFactory; // Create an instance of the URL builder $urlBuilder = UrlBuilderFactory::create('http://example.com', 'your-sign-key'); // Generate a URL $url = $urlBuilder->getUrl('cat.jpg', ['w' => 500]); // Use the URL in your app echo '<img src="'.$url.'">'; // Prints out <img src="http://example.com/img/cat.jpg?w=500&token=af3dc18fc6bfb2afb521e587c348b904"> ~~~