access-protection

How to protect against direct access to images?

纵饮孤独 提交于 2019-11-27 19:28:23
I would like to create a web site with many images. But I would like to protect against direct access to images, e.g. direct links to images without visiting the web site. What is the preferred way to do this? And what are the alternatives with Pros and cons? I have some ideas (I don't know if they are possible): File permissions PHP Sessions Temporary file names or URLs HTTP Redirection? Maybe this isn't practiced on many web sites? E.g. I tried to access a private photo on Facebook without beeing logged in, but I could still visit the photo. The platform will probably be a Ubuntu machine

How to name this key-oriented access-protection pattern?

回眸只為那壹抹淺笑 提交于 2019-11-27 14:21:14
Apparently this key-oriented access-protection pattern : class SomeKey { friend class Foo; SomeKey() {} // possibly non-copyable too }; class Bar { public: void protectedMethod(SomeKey); // only friends of SomeKey have access }; ... doesn't have a known name yet, thus i'd like to find a good one for it so we can refer to it without breaking our tongues. Suggestions? It should be: succinct convey the intent of access-protection ideally imply that no proxying is required (?) I like, in decreasing preference: passkey friend idiom passkey-door friend idiom pass-door friend idiom key-door friend

How to protect against direct access to images?

£可爱£侵袭症+ 提交于 2019-11-26 19:45:47
问题 I would like to create a web site with many images. But I would like to protect against direct access to images, e.g. direct links to images without visiting the web site. What is the preferred way to do this? And what are the alternatives with Pros and cons? I have some ideas (I don't know if they are possible): File permissions PHP Sessions Temporary file names or URLs HTTP Redirection? Maybe this isn't practiced on many web sites? E.g. I tried to access a private photo on Facebook without

How to name this key-oriented access-protection pattern?

感情迁移 提交于 2019-11-26 16:34:18
问题 Apparently this key-oriented access-protection pattern: class SomeKey { friend class Foo; SomeKey() {} // possibly non-copyable too }; class Bar { public: void protectedMethod(SomeKey); // only friends of SomeKey have access }; ... doesn't have a known name yet, thus i'd like to find a good one for it so we can refer to it without breaking our tongues. Suggestions? It should be: succinct convey the intent of access-protection ideally imply that no proxying is required (?) 回答1: I like, in

Can we increase the re-usability of this key-oriented access-protection pattern?

寵の児 提交于 2019-11-26 01:07:26
问题 Can we increase the re-usability for this key-oriented access-protection pattern: class SomeKey { friend class Foo; // more friends... ? SomeKey() {} // possibly non-copyable too }; class Bar { public: void protectedMethod(SomeKey); // only friends of SomeKey have access }; To avoid continued misunderstandings, this pattern is different from the Attorney-Client idiom: It can be more concise than Attorney-Client (as it doesn\'t involve proxying through a third class) It can allow delegation of