2017 © Pedro Peláez
 

craft-plugin serve-secret

Serve password protected files

image

itscoding/serve-secret

Serve password protected files

  • Monday, July 9, 2018
  • by boscho87
  • Repository
  • 2 Watchers
  • 7 Stars
  • 47 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 1 Open issues
  • 7 Versions
  • 0 % Grown

The README.md

ServeSecret Craft CMS 4.x plugin

Codacy Badge, (*1)

, (*2)

This Plugin is Free, but i'm happy if you want to Support my work!

Spend (go to PayPal), (*3)

QRCode (go to PayPal), (*4)


Serve files that are not Stored in public accessible Directories. e.g for Password-Protected Areas. File links could and should not be shared!, (*5)

The benefit of this is vs not having public Url's is you have a FilePreview in the CP even, the Files are not Public!, (*6)

The file links are decoded to hide the path from the user and to make the link only accessible for the current Session, so that's the reason why it's not possible to share the links!, (*7)

It's not meant to store sensitive data that possibly not should be leaked. But data that should not be found by SearchEngines or something like a ranking in a pdf file etc., (*8)

The links created by the plugin cannot be shared!, (*9)

Requirements

This plugin requires Craft CMS 4.0.0 or later., (*10)

Contribute to the Project

if you want to help with this project, read how to contribute, (*11)

Installation

To install the plugin, follow these instructions., (*12)

  1. Open your terminal and go to your Craft project:, (*13)

    cd /path/to/project
  2. Then tell Composer to load the plugin:, (*14)

    composer require itscoding/serve-secret
  3. In the Control Panel, go to Settings → Plugins and click the “Install” button for ServeSecret., (*15)

Using ServeSecret

Screenshot, (*16)

  1. Crate a volume in craft that starts with @secretStorage., (*17)

  2. add storage/secretStorage to the gitignore dire if you use the @secretStorage alias., (*18)

  3. Use it in your templates --> put your asset as a method argument!, (*19)

# the second parameter is optional, if is set to false, the file will download instead of open in the browser,the default value is true
<a href="{{ secretFile(entry.files.first(),false) }}">{{ entry.files.first().title }}</a>

{% for files in entry.files %}
       <a href="{{ secretFile(file,true) }}">{{ file.title }}</a>
{% endfor %}

ServeSecret Roadmap

Some things to do, and ideas for potential features:, (*20)

  • Create sharable fileLinks

Brought to you by Simon Müller, (*21)

The Versions

09/07 2018

dev-master

9999999-dev

Serve password protected files

  Sources   Download

MIT

The Requires

 

The Development Requires

cms craftcms craft-plugin craft servesecret

09/07 2018

1.2.1

1.2.1.0

Serve password protected files

  Sources   Download

MIT

The Requires

 

The Development Requires

cms craftcms craft-plugin craft servesecret

31/05 2018

1.2.0

1.2.0.0

Serve password protected files

  Sources   Download

MIT

The Requires

 

The Development Requires

cms craftcms craft-plugin craft servesecret

20/01 2018

dev-features/increase_to1.1

dev-features/increase_to1.1

Serve password protected files

  Sources   Download

MIT

The Requires

 

The Development Requires

cms craftcms craft-plugin craft servesecret

20/01 2018

1.1.0

1.1.0.0

Serve password protected files

  Sources   Download

MIT

The Requires

 

The Development Requires

cms craftcms craft-plugin craft servesecret

18/01 2018

1.0.0

1.0.0.0

Serve password protected files

  Sources   Download

MIT

The Requires

 

The Development Requires

cms craftcms craft-plugin craft servesecret

18/01 2018

dev-features/readme

dev-features/readme

Serve password protected files

  Sources   Download

MIT

The Requires

 

The Development Requires

cms craftcms craft-plugin craft servesecret