문제

그래서, 나는 암호를 보호하는 솔루션을 요청하는 클라이언트가있다.그는 기본적으로 opendocman과 비슷한 솔루션을 갖고 싶어합니다.그러나 그는 기본적으로 비밀번호만으로는 사용자 이름을 보호하지 못하는 다른 클라이언트에서 뭔가를 보여주었습니다.그래서 그는 파일을 업로드하고 해당 파일에 암호를 넣고 해당 파일에 직접 링크를 보내고 사용자가 암호에 묻는 메시지가 표시되고 클라이언트가 파일을 넣고 파일이 해제되고 파일이 릴리스됩니다.이 정확한 요구 사항을 수행 할 수있는 솔루션을 알고있는 사람은 누구나

도움이 되었습니까?

해결책

You can setup a basic validation page so that when a user visits a page they enter the document id (or it's encoded in the link) and you put up a simple form with a password field and a submit button.

If the password matches what is stored in the database for that document id. send that file to the user.

Keep the uploaded files outside the /web directory so you don't have to worry about people hacking the system by guessing filenames.

The files themselves won't have passwords on them, but the only way from the outside to get the file is to have the password.

다른 팁

If you don't have to have a unique password for every file, you can try apache's mod_auth. You drop a .htaccess & .htpasswd file in the directory you want to protected, and update the users/passwords in the .htpasswd file.

If you want something more dynamic, try mod_auth_mysql, so you have better control from your application.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top