Login prevention
Hello Team,
I am looking for a way to prevent non-logged-in customers from accessing my Spryker shop. I want to know where the first script runs or where the session check occurs so that I can set up login prevention without adding logic to each controller. Is there an entry point where I can implement this?
Answers
-
You can add routes to
CustomerConstants::CUSTOMER_SECURED_PATTERN
:1 -
Appreciate your assistance, @jochen.gartner . However, I'm looking to limit access to certain dynamic pages, including the product description page, that don't have static routes. How can I achieve this?
0 -
0
-
hmm, don't know. maybe you can create an EventDispatcherPlugin and redirect to /login for certain controllers.
0 -
Thanks for the suggestion! I'm not familiar with EventDispatcherPlugin. Could you provide more details or point me to a resource where I can learn more about implementing it for redirecting to /login for certain controllers? Appreciate your help!
0
Categories
- All Categories
- 42 Getting Started & Guidelines
- 7 Getting Started in the Community
- 8 Additional Resources
- 7 Community Ideas and Feedback
- 68 Spryker News
- 890 Developer Corner
- 753 Spryker Development
- 83 Spryker Dev Environment
- 360 Spryker Releases
- 3 Oryx frontend framework
- 34 Propel ORM
- 68 Community Projects
- 3 Community Ideation Board
- 30 Hackathon
- 3 PHP Bridge
- 6 Gacela Project
- 22 Job Opportunities
- 3.2K π Slack Archives
- 116 Academy
- 5 Business Users
- 370 Docker
- 551 Slack General
- 2K Help
- 75 Knowledge Sharing
- 6 Random Stuff
- 4 Code Testing
- 32 Product & Business Questions
- 68 Spryker Safari Questions
- 50 Random