Rather than a manifest, a signature? #52
Replies: 4 comments
-
Google Group Date: Sun, 1 Jun 2014 16:48:09 -0700 On Sunday, June 1, 2014 2:00:44 AM UTC-7, Dave Howell wrote:
I'm not sure how such a thing would work. Let's say a request comes in, Even if this work fine, I'm not sure it is any less difficult than storing Personally, I think if you really want to get this idea or the manifest Thanks, |
Beta Was this translation helpful? Give feedback.
-
Google Group Date: Mon, 2 Jun 2014 19:10:36 -0700 On Jun 1, 2014, at 16:48 , Jeremy Evans [email protected] wrote:
Exactly the same as you handle the form processing, period. You write whatever code would handle it.
If the signature makes sense, I absoluteiy intend to do it myself. It seems easy. My current code works based (I thought) on what you told me to do, which is this:
It’s a hard-coded manifest: there’s an order, and it will have nested items. The end. So bogus field injection won’t grant access to any other models. But it doesn’t offer any protection against injecting other fields into Order, or into other Orders, or into other Items. Signing the form would. It would make it extremely difficult to add ANY extraneous fields. This isn’t about my idea of having a single method handling all returns. That’s why I changed subjects. This is about me listening to your emphasis on security, and proposing a way to improve security of the current Forme library. |
Beta Was this translation helpful? Give feedback.
-
Google Group Date: Mon, 2 Jun 2014 22:12:30 -0700 On Monday, June 2, 2014 7:10:41 PM UTC-7, Dave Howell wrote:
Sequel's nested_attributes plugin (which Forme is designed to work with) I'd have to see your implementation of a form signature before I could Thanks, |
Beta Was this translation helpful? Give feedback.
-
Google Group Date: Tue, 3 Jun 2014 14:42:48 -0700 On Tuesday, June 3, 2014 2:14:27 PM UTC-7, Dave Howell wrote:
I'd be interested in seeing your create_hash method. This appears to be a If the form does not contain every album used to build the form, or any
The way nested_attributes handles this is it assumes any already associated Thanks, |
Beta Was this translation helpful? Give feedback.
-
Google Group Post: https://groups.google.com/g/ruby-forme/c/QKbiBKB9kB0
Google Group Date: Sun, 1 Jun 2014 02:00:40 -0700
Google Group Sender: [email protected]
As a possible alternative to a manifest for preventing malicious bogus field insertion for form data going to a universal form return routine, what about signing the form? As in, take all the keys/input field names, or maybe all the object ids, or whatever, and generate a salted cryptographic hash, a la MD5 or whatever, and then stick that into the form as a hidden field.
What data, exactly, is used as input for the hash is obviously the key to how to make this work, since it needs to be stuff that is certain to be returned with the form, so I imagine there might be some forms that it would be difficult to create a stable hash, but even if it only worked for a restricted subset of possible forms, it would still be valuable, and RESTful.
Beta Was this translation helpful? Give feedback.
All reactions