Giter Site home page Giter Site logo

Comments (5)

driesvints avatar driesvints commented on May 27, 2024 1

Hey @lupinitylabs. I feel like this isn't really dangerous as it's up to the developer to sanitise an input for the field method. Of course, you're welcome to attempt the PR to see what Taylor thinks. Thanks

from slack-notification-channel.

lupinitylabs avatar lupinitylabs commented on May 27, 2024

How would you sanitize this? The only possibility I would see is to check using is_callable() during validation if the value you try to put there is actually callable, and then filter it out...

Besides this, I feel that it is a bit of a nuisance to have to try to come up with field titles that are not function names... 😕

from slack-notification-channel.

driesvints avatar driesvints commented on May 27, 2024

Isn't $attachment->field('dd', 'Whoops') userland code? Just don't pass dd as an argument there?

from slack-notification-channel.

lupinitylabs avatar lupinitylabs commented on May 27, 2024

I can imagine several occasions where you send a slack message to a user where the user might be able to define the titles of the attachment fields. So, from my point of view, either this is flagged as something bad, and you should never use attachments even with escaped and sanitized user-provided data (then there should probably be a warning in the docs), or measures should be taken that these unexpected side-effects are not occurring? 🤔

from slack-notification-channel.

driesvints avatar driesvints commented on May 27, 2024

I personally don't see a situation where a user would ever fill this out themselves but if you do feel free to attempt a PR to improve this 👍

from slack-notification-channel.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.