Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUGFIX] transmitting value objects by identifier #1

Closed
wants to merge 1 commit into from

Conversation

kaystrobach
Copy link
Contributor

given:

/**
     * @param Article\Keyword $keyword
     */
    public function showKeywordAction(Article\Keyword $keyword) {
….
<f:link.action action="showKeyword" arguments="{keyword:keyword}" class="btn btn-default btn-sm“>

...
/**
 * @Flow\ValueObject
 */
class Keyword
{
    /**
     * @var string
     */
    protected $keyword;

    public function __construct($keyword) {
        $this->keyword = $keyword;
    }
...

url looks like: /article/showkeyword?keyword%5B__identity%5D=761842cbf8e2c16abac74a60aaeada1b6203f4a9

and the exceptions are:
#1297759968: Exception while property mapping for target type "SBS\Materialdatenbank\Domain\Model\Article\Keyword", at property path "": Missing constructor argument "keyword" for object of type "SBS\Materialdatenbank\Domain\Model\Article\Keyword“.
#1268734872: Missing constructor argument "keyword" for object of type "SBS\Materialdatenbank\Domain\Model\Article\Keyword".

I do use FLOW 3.0.0 in that project

@kaystrobach kaystrobach changed the title [BUGFIX] Fix transmitting value objects by identifier [BUGFIX] transmitting value objects by identifier Oct 13, 2015
@kaystrobach
Copy link
Contributor Author

closed, followup in neos/flow-development-collection#90 ... 😢

@kaystrobach kaystrobach deleted the patch-1 branch October 13, 2015 08:31
@kitsunet
Copy link
Member

The thing is, that I am not sure this is the best way to fix it. Actually the other side should be fixed. A value object should be represented by value(s) and not by identity. In this case the identity is even more a necessary technical construct that should be kept internally.

IMHO the url should look like:
article/showkeyword?keyword%5Bkeyword%5D=something
I guess that makes a change in the argument mapping for links necessary. Maybe @bwaidelich or @skurfuerst have an opinion on that?

neos-bot pushed a commit that referenced this pull request Nov 1, 2016
The ``PersistedUsernamePasswordProvider`` was prone to a information
disclosure of account existance based on timing attacks as the
hashing of passwords was only done in case an account was found.

This change refactors the provider to always do a password comparison
in case credentials were submitted at all.

Fixes #1
neos-bot pushed a commit that referenced this pull request Apr 3, 2017
The ``PersistedUsernamePasswordProvider`` was prone to a information
disclosure of account existance based on timing attacks as the
hashing of passwords was only done in case an account was found.

This change refactors the provider to always do a password comparison
in case credentials were submitted at all.

Fixes #1
kdambekalns pushed a commit that referenced this pull request Nov 13, 2017
The ``PersistedUsernamePasswordProvider`` was prone to a information
disclosure of account existance based on timing attacks as the
hashing of passwords was only done in case an account was found.

This change refactors the provider to always do a password comparison
in case credentials were submitted at all.

Fixes #1
neos-bot pushed a commit that referenced this pull request Nov 9, 2023
…ject

> Parameter #1 $objectName of method ObjectManager::get() expects class-string<Some.Package:VirtualObject>, string given.

instead we will return `object`

Phpstorm doesnt support his conditional return type so we have a simple `@return T` in place which allows for autocompletion
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants