Skip to content

Commit 36764e4

Browse files
committed
0.1.10
1 parent 4fd464a commit 36764e4

File tree

5 files changed

+141
-5
lines changed

5 files changed

+141
-5
lines changed

.env

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,3 +35,9 @@ DATABASE_URL=mysql://db_user:db_password@127.0.0.1:3306/db_name?serverVersion=5.
3535
###> nelmio/cors-bundle ###
3636
CORS_ALLOW_ORIGIN=^https?://(localhost|127\.0\.0\.1)(:[0-9]+)?$
3737
###< nelmio/cors-bundle ###
38+
39+
###> symfony/lock ###
40+
# Choose one of the stores below
41+
# postgresql+advisory://db_user:db_password@localhost/db_name
42+
LOCK_DSN=semaphore
43+
###< symfony/lock ###

.gitignore

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,4 +27,8 @@ public/uploads/
2727

2828
###> liip/imagine-bundle ###
2929
/public/media/cache/
30-
###< liip/imagine-bundle ###
30+
###< liip/imagine-bundle ###
31+
###> phpunit/phpunit ###
32+
/phpunit.xml
33+
.phpunit.result.cache
34+
###< phpunit/phpunit ###

config/packages/lock.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
framework:
2+
lock: '%env(LOCK_DSN)%'

config/packages/security.yaml

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,10 @@ security:
33
Teebb\CoreBundle\Entity\User:
44
algorithm: auto
55

6+
# https://symfony.com/doc/current/security/experimental_authenticators.html
7+
enable_authenticator_manager: true
68
# https://symfony.com/doc/current/security.html#where-do-users-come-from-user-providers
9+
710
providers:
811
user_provider:
912
entity:
@@ -15,18 +18,23 @@ security:
1518
pattern: ^/(_(profiler|wdt)|css|images|js)/
1619
security: false
1720
main:
18-
anonymous: lazy
21+
lazy: true
1922
provider: user_provider
2023

2124
logout:
2225
path: teebb_user_logout
2326

24-
guard:
25-
authenticators:
26-
- Teebb\CoreBundle\Security\LoginFormAuthenticator
27+
# 弃用,从symfony5.3版本起使用新的认证系统
28+
# guard:
29+
# authenticators:
30+
# - Teebb\CoreBundle\Security\LoginFormAuthenticator
31+
custom_authenticator: Teebb\CoreBundle\Security\AppLoginFormAuthenticator
2732

2833
user_checker: Teebb\CoreBundle\Security\UserChecker
2934

35+
login_throttling:
36+
max_attempts: 3
37+
3038
remember_me:
3139
secret: '%kernel.secret%'
3240
lifetime: 604800 # 7 days in seconds

symfony.lock

Lines changed: 116 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,9 @@
4646
"doctrine/dbal": {
4747
"version": "2.10.2"
4848
},
49+
"doctrine/deprecations": {
50+
"version": "v0.5.3"
51+
},
4952
"doctrine/doctrine-bundle": {
5053
"version": "2.0",
5154
"recipe": {
@@ -186,6 +189,9 @@
186189
"monolog/monolog": {
187190
"version": "2.0.2"
188191
},
192+
"myclabs/deep-copy": {
193+
"version": "1.10.2"
194+
},
189195
"nelmio/cors-bundle": {
190196
"version": "1.5",
191197
"recipe": {
@@ -219,6 +225,12 @@
219225
"pagerfanta/pagerfanta": {
220226
"version": "v2.3.0"
221227
},
228+
"phar-io/manifest": {
229+
"version": "2.0.3"
230+
},
231+
"phar-io/version": {
232+
"version": "3.1.0"
233+
},
222234
"php": {
223235
"version": "7.3"
224236
},
@@ -231,9 +243,41 @@
231243
"phpdocumentor/type-resolver": {
232244
"version": "1.1.0"
233245
},
246+
"phpspec/prophecy": {
247+
"version": "1.13.0"
248+
},
234249
"phpstan/phpdoc-parser": {
235250
"version": "0.4.10"
236251
},
252+
"phpunit/php-code-coverage": {
253+
"version": "9.2.6"
254+
},
255+
"phpunit/php-file-iterator": {
256+
"version": "3.0.5"
257+
},
258+
"phpunit/php-invoker": {
259+
"version": "3.1.1"
260+
},
261+
"phpunit/php-text-template": {
262+
"version": "2.0.4"
263+
},
264+
"phpunit/php-timer": {
265+
"version": "5.0.3"
266+
},
267+
"phpunit/phpunit": {
268+
"version": "9.3",
269+
"recipe": {
270+
"repo": "github.com/symfony/recipes",
271+
"branch": "master",
272+
"version": "9.3",
273+
"ref": "a6249a6c4392e9169b87abf93225f7f9f59025e6"
274+
},
275+
"files": [
276+
".env.test",
277+
"phpunit.xml.dist",
278+
"tests/bootstrap.php"
279+
]
280+
},
237281
"psr/cache": {
238282
"version": "1.0.1"
239283
},
@@ -249,6 +293,54 @@
249293
"psr/log": {
250294
"version": "1.1.3"
251295
},
296+
"sebastian/cli-parser": {
297+
"version": "1.0.1"
298+
},
299+
"sebastian/code-unit": {
300+
"version": "1.0.8"
301+
},
302+
"sebastian/code-unit-reverse-lookup": {
303+
"version": "2.0.3"
304+
},
305+
"sebastian/comparator": {
306+
"version": "4.0.6"
307+
},
308+
"sebastian/complexity": {
309+
"version": "2.0.2"
310+
},
311+
"sebastian/diff": {
312+
"version": "4.0.4"
313+
},
314+
"sebastian/environment": {
315+
"version": "5.1.3"
316+
},
317+
"sebastian/exporter": {
318+
"version": "4.0.3"
319+
},
320+
"sebastian/global-state": {
321+
"version": "5.0.3"
322+
},
323+
"sebastian/lines-of-code": {
324+
"version": "1.0.3"
325+
},
326+
"sebastian/object-enumerator": {
327+
"version": "4.0.4"
328+
},
329+
"sebastian/object-reflector": {
330+
"version": "2.0.4"
331+
},
332+
"sebastian/recursion-context": {
333+
"version": "4.0.4"
334+
},
335+
"sebastian/resource-operations": {
336+
"version": "3.0.3"
337+
},
338+
"sebastian/type": {
339+
"version": "2.3.4"
340+
},
341+
"sebastian/version": {
342+
"version": "3.0.2"
343+
},
252344
"sensio/framework-extra-bundle": {
253345
"version": "5.2",
254346
"recipe": {
@@ -426,6 +518,18 @@
426518
"symfony/intl": {
427519
"version": "v5.0.8"
428520
},
521+
"symfony/lock": {
522+
"version": "5.2",
523+
"recipe": {
524+
"repo": "github.com/symfony/recipes",
525+
"branch": "master",
526+
"version": "5.2",
527+
"ref": "a1c8800e40ae735206bb14586fdd6c4630a51b8d"
528+
},
529+
"files": [
530+
"config/packages/lock.yaml"
531+
]
532+
},
429533
"symfony/mailer": {
430534
"version": "4.3",
431535
"recipe": {
@@ -485,6 +589,9 @@
485589
"symfony/orm-pack": {
486590
"version": "v1.0.8"
487591
},
592+
"symfony/password-hasher": {
593+
"version": "v5.3.4"
594+
},
488595
"symfony/phpunit-bridge": {
489596
"version": "4.3",
490597
"recipe": {
@@ -521,6 +628,9 @@
521628
"symfony/polyfill-php80": {
522629
"version": "v1.18.0"
523630
},
631+
"symfony/polyfill-php81": {
632+
"version": "v1.23.0"
633+
},
524634
"symfony/process": {
525635
"version": "v5.0.8"
526636
},
@@ -533,6 +643,9 @@
533643
"symfony/property-info": {
534644
"version": "v5.0.8"
535645
},
646+
"symfony/rate-limiter": {
647+
"version": "v5.3.4"
648+
},
536649
"symfony/routing": {
537650
"version": "4.2",
538651
"recipe": {
@@ -670,6 +783,9 @@
670783
"teebbstudios/core-bundle": {
671784
"version": "0.1.0"
672785
},
786+
"theseer/tokenizer": {
787+
"version": "1.2.1"
788+
},
673789
"twig/extra-bundle": {
674790
"version": "v3.0.3"
675791
},

0 commit comments

Comments
 (0)