阶段八:完成登录审计资料repository收口
This commit is contained in:
1 parent
98023744fa
commit
a1bf5078d8
6 files changed
+214
-186
No files matched your search
+148
-160
@@ -64117,322 +64117,328 @@
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 177,
|
||||
"kind": "function",
|
||||
"name": "updateFlatCookieOwnedLocked"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 181,
|
||||
"kind": "local-variable",
|
||||
"name": "metadata"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 185,
|
||||
"line": 174,
|
||||
"kind": "function",
|
||||
"name": "updateRunningCookie"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 190,
|
||||
"line": 181,
|
||||
"kind": "local-variable",
|
||||
"name": "ok"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 190,
|
||||
"line": 181,
|
||||
"kind": "local-variable",
|
||||
"name": "sender"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 195,
|
||||
"line": 186,
|
||||
"kind": "function",
|
||||
"name": "wakeCredentialBlockedAutomation"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 199,
|
||||
"line": 190,
|
||||
"kind": "local-variable",
|
||||
"name": "err"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 204,
|
||||
"line": 195,
|
||||
"kind": "function",
|
||||
"name": "scopedCookieHeader"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 208,
|
||||
"line": 199,
|
||||
"kind": "local-variable",
|
||||
"name": "ok"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 208,
|
||||
"line": 199,
|
||||
"kind": "local-variable",
|
||||
"name": "snapshot"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 209,
|
||||
"line": 200,
|
||||
"kind": "local-variable",
|
||||
"name": "authoritative"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 209,
|
||||
"line": 200,
|
||||
"kind": "local-variable",
|
||||
"name": "header"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 216,
|
||||
"line": 207,
|
||||
"kind": "type",
|
||||
"name": "updateCookieSettingsRequest"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 230,
|
||||
"line": 221,
|
||||
"kind": "local-variable",
|
||||
"name": "cid"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 231,
|
||||
"line": 222,
|
||||
"kind": "local-variable",
|
||||
"name": "detail"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 231,
|
||||
"line": 222,
|
||||
"kind": "local-variable",
|
||||
"name": "ok"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 235,
|
||||
"line": 226,
|
||||
"kind": "var",
|
||||
"name": "req"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 236,
|
||||
"line": 227,
|
||||
"kind": "local-variable",
|
||||
"name": "err"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 257,
|
||||
"line": 248,
|
||||
"kind": "local-variable",
|
||||
"name": "credentialUnlock"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 258,
|
||||
"line": 249,
|
||||
"kind": "local-variable",
|
||||
"name": "err"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 258,
|
||||
"line": 249,
|
||||
"kind": "local-variable",
|
||||
"name": "latestDetail"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 266,
|
||||
"line": 257,
|
||||
"kind": "local-variable",
|
||||
"name": "input"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 274,
|
||||
"line": 265,
|
||||
"kind": "local-variable",
|
||||
"name": "loginChanged"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 276,
|
||||
"line": 267,
|
||||
"kind": "local-variable",
|
||||
"name": "username"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 280,
|
||||
"line": 271,
|
||||
"kind": "local-variable",
|
||||
"name": "password"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 287,
|
||||
"line": 278,
|
||||
"kind": "local-variable",
|
||||
"name": "showBrowser"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 295,
|
||||
"line": 286,
|
||||
"kind": "local-variable",
|
||||
"name": "err"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 295,
|
||||
"line": 286,
|
||||
"kind": "local-variable",
|
||||
"name": "pausedUntil"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 312,
|
||||
"line": 303,
|
||||
"kind": "local-variable",
|
||||
"name": "err"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 319,
|
||||
"line": 310,
|
||||
"kind": "local-variable",
|
||||
"name": "err"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 450,
|
||||
"line": 441,
|
||||
"kind": "local-variable",
|
||||
"name": "err"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 450,
|
||||
"line": 441,
|
||||
"kind": "local-variable",
|
||||
"name": "profile"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 480,
|
||||
"line": 471,
|
||||
"kind": "var",
|
||||
"name": "req"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 485,
|
||||
"line": 476,
|
||||
"kind": "local-variable",
|
||||
"name": "err"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 489,
|
||||
"line": 480,
|
||||
"kind": "local-variable",
|
||||
"name": "sess"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 490,
|
||||
"line": 481,
|
||||
"kind": "local-variable",
|
||||
"name": "err"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 498,
|
||||
"kind": "local-variable",
|
||||
"name": "cid"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 499,
|
||||
"kind": "local-variable",
|
||||
"name": "ok"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 503,
|
||||
"kind": "var",
|
||||
"name": "req"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 507,
|
||||
"kind": "local-variable",
|
||||
"name": "cid"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 508,
|
||||
"kind": "local-variable",
|
||||
"name": "ok"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 512,
|
||||
"kind": "var",
|
||||
"name": "req"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 516,
|
||||
"kind": "local-variable",
|
||||
"name": "err"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 520,
|
||||
"line": 511,
|
||||
"kind": "local-variable",
|
||||
"name": "sess"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 521,
|
||||
"line": 512,
|
||||
"kind": "local-variable",
|
||||
"name": "err"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 534,
|
||||
"line": 525,
|
||||
"kind": "local-variable",
|
||||
"name": "cid"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 535,
|
||||
"line": 526,
|
||||
"kind": "local-variable",
|
||||
"name": "detail"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 535,
|
||||
"line": 526,
|
||||
"kind": "local-variable",
|
||||
"name": "ok"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 539,
|
||||
"line": 530,
|
||||
"kind": "var",
|
||||
"name": "req"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 546,
|
||||
"line": 537,
|
||||
"kind": "local-variable",
|
||||
"name": "err"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 550,
|
||||
"line": 541,
|
||||
"kind": "local-variable",
|
||||
"name": "password"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 559,
|
||||
"line": 550,
|
||||
"kind": "local-variable",
|
||||
"name": "err"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 568,
|
||||
"line": 559,
|
||||
"kind": "local-variable",
|
||||
"name": "cid"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 569,
|
||||
"line": 560,
|
||||
"kind": "local-variable",
|
||||
"name": "ok"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 569,
|
||||
"line": 560,
|
||||
"kind": "local-variable",
|
||||
"name": "ownedDetail"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 573,
|
||||
"line": 564,
|
||||
"kind": "var",
|
||||
"name": "req"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 567,
|
||||
"kind": "local-variable",
|
||||
"name": "err"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 571,
|
||||
"kind": "local-variable",
|
||||
"name": "reason"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 575,
|
||||
"kind": "local-variable",
|
||||
"name": "credentialUnlock"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 576,
|
||||
@@ -64441,319 +64447,301 @@
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 580,
|
||||
"kind": "local-variable",
|
||||
"name": "reason"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 584,
|
||||
"kind": "local-variable",
|
||||
"name": "credentialUnlock"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 585,
|
||||
"kind": "local-variable",
|
||||
"name": "err"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 585,
|
||||
"line": 576,
|
||||
"kind": "local-variable",
|
||||
"name": "latest"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 591,
|
||||
"line": 582,
|
||||
"kind": "local-variable",
|
||||
"name": "err"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 602,
|
||||
"line": 593,
|
||||
"kind": "local-variable",
|
||||
"name": "err"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 615,
|
||||
"line": 606,
|
||||
"kind": "local-variable",
|
||||
"name": "cid"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 616,
|
||||
"line": 607,
|
||||
"kind": "local-variable",
|
||||
"name": "ok"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 616,
|
||||
"line": 607,
|
||||
"kind": "local-variable",
|
||||
"name": "ownedDetail"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 620,
|
||||
"line": 611,
|
||||
"kind": "local-variable",
|
||||
"name": "credentialUnlock"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 621,
|
||||
"line": 612,
|
||||
"kind": "local-variable",
|
||||
"name": "err"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 621,
|
||||
"line": 612,
|
||||
"kind": "local-variable",
|
||||
"name": "latest"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 627,
|
||||
"line": 618,
|
||||
"kind": "local-variable",
|
||||
"name": "err"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 648,
|
||||
"line": 639,
|
||||
"kind": "local-variable",
|
||||
"name": "cid"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 652,
|
||||
"line": 643,
|
||||
"kind": "var",
|
||||
"name": "req"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 655,
|
||||
"line": 646,
|
||||
"kind": "local-variable",
|
||||
"name": "err"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 661,
|
||||
"line": 652,
|
||||
"kind": "local-variable",
|
||||
"name": "err"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 672,
|
||||
"line": 663,
|
||||
"kind": "local-variable",
|
||||
"name": "cid"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 673,
|
||||
"line": 664,
|
||||
"kind": "local-variable",
|
||||
"name": "d"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 673,
|
||||
"line": 664,
|
||||
"kind": "local-variable",
|
||||
"name": "ok"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 682,
|
||||
"line": 673,
|
||||
"kind": "local-variable",
|
||||
"name": "cid"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 677,
|
||||
"kind": "var",
|
||||
"name": "req"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 680,
|
||||
"kind": "local-variable",
|
||||
"name": "err"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 686,
|
||||
"kind": "var",
|
||||
"name": "req"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 689,
|
||||
"kind": "local-variable",
|
||||
"name": "err"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 695,
|
||||
"kind": "local-variable",
|
||||
"name": "err"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 706,
|
||||
"line": 697,
|
||||
"kind": "local-variable",
|
||||
"name": "cid"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 710,
|
||||
"line": 701,
|
||||
"kind": "var",
|
||||
"name": "req"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 713,
|
||||
"line": 704,
|
||||
"kind": "local-variable",
|
||||
"name": "err"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 721,
|
||||
"line": 712,
|
||||
"kind": "local-variable",
|
||||
"name": "err"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 721,
|
||||
"line": 712,
|
||||
"kind": "local-variable",
|
||||
"name": "pausedUntil"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 733,
|
||||
"line": 724,
|
||||
"kind": "local-variable",
|
||||
"name": "cid"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 737,
|
||||
"line": 728,
|
||||
"kind": "local-variable",
|
||||
"name": "paused"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 737,
|
||||
"line": 728,
|
||||
"kind": "local-variable",
|
||||
"name": "pausedUntil"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 745,
|
||||
"line": 736,
|
||||
"kind": "function",
|
||||
"name": "refreshAccountProfile"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 753,
|
||||
"line": 749,
|
||||
"kind": "local-variable",
|
||||
"name": "credentialUnlock"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 754,
|
||||
"line": 750,
|
||||
"kind": "local-variable",
|
||||
"name": "latest"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 754,
|
||||
"line": 750,
|
||||
"kind": "local-variable",
|
||||
"name": "latestErr"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 762,
|
||||
"line": 758,
|
||||
"kind": "local-variable",
|
||||
"name": "cookieSession"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 762,
|
||||
"line": 758,
|
||||
"kind": "local-variable",
|
||||
"name": "mtopCtx"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 763,
|
||||
"line": 759,
|
||||
"kind": "local-variable",
|
||||
"name": "callErr"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 763,
|
||||
"line": 759,
|
||||
"kind": "local-variable",
|
||||
"name": "profile"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 764,
|
||||
"line": 760,
|
||||
"kind": "local-variable",
|
||||
"name": "runtimeCookie"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 765,
|
||||
"line": 761,
|
||||
"kind": "local-variable",
|
||||
"name": "runtimeCookieChanged"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 766,
|
||||
"line": 762,
|
||||
"kind": "local-variable",
|
||||
"name": "handled"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 766,
|
||||
"line": 762,
|
||||
"kind": "local-variable",
|
||||
"name": "persistErr"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 766,
|
||||
"line": 762,
|
||||
"kind": "local-variable",
|
||||
"name": "value"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 766,
|
||||
"line": 762,
|
||||
"kind": "local-variable",
|
||||
"name": "valueChanged"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 781,
|
||||
"line": 777,
|
||||
"kind": "local-variable",
|
||||
"name": "err"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 807,
|
||||
"line": 803,
|
||||
"kind": "local-variable",
|
||||
"name": "apiNickname"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 808,
|
||||
"line": 804,
|
||||
"kind": "local-variable",
|
||||
"name": "apiAvatarURL"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 809,
|
||||
"line": 805,
|
||||
"kind": "local-variable",
|
||||
"name": "err"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 821,
|
||||
"line": 817,
|
||||
"kind": "function",
|
||||
"name": "cachedAccountNickname"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 831,
|
||||
"line": 827,
|
||||
"kind": "function",
|
||||
"name": "normalizeProfileAvatarURL"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/cookie_handlers.go",
|
||||
"line": 845,
|
||||
"line": 841,
|
||||
"kind": "function",
|
||||
"name": "truncate"
|
||||
},
|
||||
@@ -74155,37 +74143,37 @@
|
||||
},
|
||||
{
|
||||
"file": "internal/server/login_audit.go",
|
||||
"line": 37,
|
||||
"line": 42,
|
||||
"kind": "local-variable",
|
||||
"name": "at"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/login_audit.go",
|
||||
"line": 38,
|
||||
"line": 43,
|
||||
"kind": "local-variable",
|
||||
"name": "err"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/login_audit.go",
|
||||
"line": 45,
|
||||
"line": 50,
|
||||
"kind": "local-variable",
|
||||
"name": "err"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/login_audit.go",
|
||||
"line": 52,
|
||||
"line": 57,
|
||||
"kind": "function",
|
||||
"name": "addLoginLog"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/login_audit.go",
|
||||
"line": 59,
|
||||
"line": 66,
|
||||
"kind": "local-variable",
|
||||
"name": "err"
|
||||
},
|
||||
{
|
||||
"file": "internal/server/login_audit.go",
|
||||
"line": 76,
|
||||
"line": 83,
|
||||
"kind": "function",
|
||||
"name": "loginTriggerReason"
|
||||
},
|
||||
|
||||
@@ -618,3 +618,4 @@ npm --prefix frontend run build
|
||||
| 2026-08-15 | 完成阶段 8 第六个 PR 切片“发布应用服务 repository 边界” | 新增 `itemPublishRepository`,单商品发布、类目推荐、预检批次创建、批次查询/取消/删除/失败重试及凭证 Cookie 持久化不再直接访问完整 `db.Store`;批量 worker 的租约状态机和后台生命周期暂保持原有 Server 接线,下一片整体迁移;单商品/批量发布测试、Go vet、lint、注释和全量门禁通过并合并为一个可回滚提交 | 阶段 8:发布 worker 租约状态机 repository 边界 |
|
||||
| 2026-08-15 | 完成阶段 8 第七个 PR 切片“发布 worker 租约状态机 repository 边界” | 发布恢复扫描、批次租约续期、明细抢占、远端发布检查点、结果落库、取消/中断收口和过期上传清理统一通过 `itemPublishRepository`;worker 不再直接访问 `PublishBatches`、Cookies 或 Items,平台 MTOP、自动化规则和生命周期等待语义保持不变;Server 全量测试、Server race、Go vet、lint、注释和全量门禁通过并合并为一个可回滚提交 | 阶段 8:账号登录应用服务 repository 边界 |
|
||||
| 2026-08-15 | 完成阶段 8 第八个 PR 切片“账号登录凭证与 Token repository 边界” | 新增 `accountLoginRepository`,账号登录服务的凭证创建/更新、Cookie Jar 元数据写回、凭证锁、Token 清理和运行状态读取统一通过窄接口;保留登录服务对资料刷新、登录审计和运行时重启的既有编排,未改变扫码幂等、Cookie 合并与凭证锁时序;Server 全量测试、Server race、Go vet、lint、注释和全量门禁通过并合并为一个可回滚提交 | 阶段 8:登录审计与资料刷新共享 repository 边界 |
|
||||
| 2026-08-15 | 完成阶段 8 第九个 PR 切片“登录审计与资料刷新共享 repository 边界” | 登录方式/状态、登录审计日志、账号资料更新、资料刷新凭证锁与平台视图读取统一通过 `accountLoginRepository`;运行时 Cookie 更新复用同一账号状态边界,移除无调用方的旧扁平 Cookie helper,保持 MTOP Cookie Jar 合并、资料刷新失败恢复和运行时唤醒语义不变;Server 全量测试、Server race、Go vet、lint、注释和全量门禁通过并合并为一个可回滚提交 | 阶段 8:数据库直连与事务边界最终审计 |
|
||||
@@ -8,7 +8,7 @@ import (
|
||||
"xianyu-go/internal/xianyu/cookierefresh"
|
||||
)
|
||||
|
||||
// accountLoginRepository 定义账号登录服务写入凭证、清理 Token 和读取账号状态所需的最小能力。
|
||||
// accountLoginRepository 定义账号登录服务写入凭证、审计登录、更新资料和读取账号状态所需的最小能力。
|
||||
type accountLoginRepository interface {
|
||||
// LockCredentials 串行化账号登录凭证变更。
|
||||
LockCredentials(accountID string) func()
|
||||
@@ -24,6 +24,14 @@ type accountLoginRepository interface {
|
||||
ClearTokens(ctx context.Context, accountID string) error
|
||||
// GetStatus 返回账号是否启用。
|
||||
GetStatus(ctx context.Context, accountID string) bool
|
||||
// MarkLogin 保存账号最近一次成功登录方式。
|
||||
MarkLogin(ctx context.Context, accountID, method string, at int64) error
|
||||
// SetStatusWithReason 更新账号启用状态及禁用原因。
|
||||
SetStatusWithReason(ctx context.Context, accountID string, enabled bool, reason string) error
|
||||
// AddLoginLog 写入账号登录审计记录。
|
||||
AddLoginLog(ctx context.Context, log db.AccountLoginLog) error
|
||||
// UpdateProfile 保存账号展示资料。
|
||||
UpdateProfile(ctx context.Context, accountID, nickname, avatarURL string) error
|
||||
}
|
||||
|
||||
// storeAccountLoginRepository 将完整 Store 适配为账号登录服务窄 repository。
|
||||
@@ -80,6 +88,29 @@ func (r storeAccountLoginRepository) GetStatus(ctx context.Context, accountID st
|
||||
return r.store.Cookies.GetStatus(ctx, accountID)
|
||||
}
|
||||
|
||||
// MarkLogin 委托账号最近一次成功登录方式保存。
|
||||
func (r storeAccountLoginRepository) MarkLogin(ctx context.Context, accountID, method string, at int64) error {
|
||||
return r.store.Cookies.MarkLogin(ctx, accountID, method, at)
|
||||
}
|
||||
|
||||
// SetStatusWithReason 委托账号启用状态更新。
|
||||
func (r storeAccountLoginRepository) SetStatusWithReason(ctx context.Context, accountID string, enabled bool, reason string) error {
|
||||
return r.store.Cookies.SetStatusWithReason(ctx, accountID, enabled, reason)
|
||||
}
|
||||
|
||||
// AddLoginLog 委托账号登录审计记录写入;未启用审计 repository 时保持兼容空操作。
|
||||
func (r storeAccountLoginRepository) AddLoginLog(ctx context.Context, log db.AccountLoginLog) error {
|
||||
if r.store.LoginLogs == nil {
|
||||
return nil
|
||||
}
|
||||
return r.store.LoginLogs.Add(ctx, log)
|
||||
}
|
||||
|
||||
// UpdateProfile 委托账号展示资料更新。
|
||||
func (r storeAccountLoginRepository) UpdateProfile(ctx context.Context, accountID, nickname, avatarURL string) error {
|
||||
return r.store.Cookies.UpdateProfile(ctx, accountID, nickname, avatarURL)
|
||||
}
|
||||
|
||||
// newStoreAccountLoginRepository 从完整 Store 构造账号登录服务窄 repository。
|
||||
func newStoreAccountLoginRepository(store *db.Store) accountLoginRepository {
|
||||
if store == nil || store.Cookies == nil {
|
||||
|
||||
@@ -20,6 +20,16 @@ type accountLoginService struct {
|
||||
repository accountLoginRepository
|
||||
}
|
||||
|
||||
// accountLoginApplication 返回当前 Server 绑定的账号登录应用服务。
|
||||
func (s *Server) accountLoginApplication() *accountLoginService {
|
||||
return s.applicationServiceSet().accountLogin
|
||||
}
|
||||
|
||||
// accountLoginRepositoryForServer 返回当前 Server 装配的账号登录持久化边界。
|
||||
func (s *Server) accountLoginRepositoryForServer() accountLoginRepository {
|
||||
return s.accountLoginApplication().repository
|
||||
}
|
||||
|
||||
// accountLoginInput 是新增账号登录凭证用例的业务输入。
|
||||
type accountLoginInput struct {
|
||||
// AccountID 是待创建的账号标识。
|
||||
@@ -54,11 +64,6 @@ type accountProfileResult struct {
|
||||
ErrorMessage string
|
||||
}
|
||||
|
||||
// accountLoginApplication 返回当前 Server 绑定的账号登录应用服务。
|
||||
func (s *Server) accountLoginApplication() *accountLoginService {
|
||||
return s.applicationServiceSet().accountLogin
|
||||
}
|
||||
|
||||
// CreateCookie 创建账号凭证并完成登录审计、资料刷新和运行时重启。
|
||||
func (svc *accountLoginService) CreateCookie(ctx context.Context, input accountLoginInput) error {
|
||||
// s 是当前账号登录应用服务依赖的 Server。
|
||||
|
||||
@@ -171,20 +171,11 @@ func (s *Server) persistLongLoginCookies(ctx context.Context, detail *db.CookieD
|
||||
return credentialChanged, nil
|
||||
}
|
||||
|
||||
// updateFlatCookieOwnedLocked 用新的扁平 Cookie 覆盖账号时同步移除旧浏览器
|
||||
// 快照,避免下一次浏览器取 token 又把旧 Cookie 注入回来。调用方必须持有
|
||||
// 对应账号的凭证锁,并已验证 detail 的归属。
|
||||
func (s *Server) updateFlatCookieOwnedLocked(ctx context.Context, detail *db.CookieDetail, value string) error {
|
||||
if detail == nil {
|
||||
return db.ErrNotFound
|
||||
}
|
||||
metadata := cookierefresh.MetadataWithoutSnapshot(detail.MetadataJSON)
|
||||
return s.Store.Cookies.UpdateRenewalCookie(ctx, detail.ID, value, metadata, time.Now().Unix())
|
||||
}
|
||||
|
||||
func (s *Server) updateRunningCookie(ctx context.Context, cookieID, value string) {
|
||||
s.wakeCredentialBlockedAutomation(ctx, cookieID)
|
||||
if s.Manager == nil || !s.Store.Cookies.GetStatus(ctx, cookieID) {
|
||||
// repository 提供运行时更新前的账号启用状态读取。
|
||||
repository := s.accountLoginRepositoryForServer()
|
||||
if s.Manager == nil || repository == nil || !repository.GetStatus(ctx, cookieID) {
|
||||
return
|
||||
}
|
||||
if sender, ok := s.Manager.GetInstance(cookieID); ok {
|
||||
@@ -750,8 +741,13 @@ func (s *Server) refreshAccountProfile(ctx context.Context, d *db.CookieDetail)
|
||||
return cachedAccountNickname(d), d.AvatarURL, "账号资料客户端未初始化"
|
||||
}
|
||||
|
||||
credentialUnlock := s.Store.LockAccountCredentials(d.ID)
|
||||
latest, latestErr := s.loadCookiePlatformDetail(ctx, d.ID)
|
||||
// repository 提供资料刷新所需的凭证锁、平台视图和资料持久化能力。
|
||||
repository := s.accountLoginRepositoryForServer()
|
||||
if repository == nil {
|
||||
return cachedAccountNickname(d), d.AvatarURL, "账号登录持久化未初始化"
|
||||
}
|
||||
credentialUnlock := repository.LockCredentials(d.ID)
|
||||
latest, latestErr := repository.LoadPlatformDetail(ctx, d.ID)
|
||||
if latestErr != nil || latest == nil || latest.UserID != d.UserID {
|
||||
credentialUnlock()
|
||||
if latestErr == nil {
|
||||
@@ -778,7 +774,7 @@ func (s *Server) refreshAccountProfile(ctx context.Context, d *db.CookieDetail)
|
||||
} else if callErr == nil && profile != nil && profile.UpdatedCookies != "" && profile.UpdatedCookies != latest.Value {
|
||||
// 注入 mock 或没有权威快照的历史账号继续沿用扁平 Cookie 路径;
|
||||
// 该路径必须清除旧 snapshot,不能伪造完整 Jar。
|
||||
if err := s.updateFlatCookieOwnedLocked(ctx, latest, profile.UpdatedCookies); err != nil {
|
||||
if err := repository.UpdateFlatCookieOwned(ctx, latest, profile.UpdatedCookies); err != nil {
|
||||
if s.Logger != nil {
|
||||
s.Logger.Warn("保存账号刷新 cookie 失败", "account", d.ID, "err", err)
|
||||
}
|
||||
@@ -806,7 +802,7 @@ func (s *Server) refreshAccountProfile(ctx context.Context, d *db.CookieDetail)
|
||||
|
||||
apiNickname := strings.TrimSpace(profile.Nickname)
|
||||
apiAvatarURL := normalizeProfileAvatarURL(profile.AvatarURL)
|
||||
if err := s.Store.Cookies.UpdateProfile(ctx, d.ID, apiNickname, apiAvatarURL); err != nil && s.Logger != nil {
|
||||
if err := repository.UpdateProfile(ctx, d.ID, apiNickname, apiAvatarURL); err != nil && s.Logger != nil {
|
||||
s.Logger.Warn("保存账号资料失败", "account", d.ID, "err", err)
|
||||
}
|
||||
if apiNickname == "" {
|
||||
|
||||
@@ -30,19 +30,24 @@ func normalizeLoginMethod(method string) string {
|
||||
}
|
||||
|
||||
func (s *Server) markSuccessfulLogin(ctx context.Context, cookieID string, userID int64, method, message string) {
|
||||
// repository 提供登录审计和账号状态持久化能力。
|
||||
repository := s.accountLoginRepositoryForServer()
|
||||
if repository == nil {
|
||||
return
|
||||
}
|
||||
method = normalizeLoginMethod(method)
|
||||
if method == "" {
|
||||
return
|
||||
}
|
||||
at := time.Now().Unix()
|
||||
if err := s.Store.Cookies.MarkLogin(ctx, cookieID, method, at); err != nil {
|
||||
if err := repository.MarkLogin(ctx, cookieID, method, at); err != nil {
|
||||
if s.Logger != nil {
|
||||
s.Logger.Warn("记录账号登录方式失败", "cookie_id", cookieID, "method", method, "err", err)
|
||||
}
|
||||
return
|
||||
}
|
||||
if method == loginMethodPassword || method == loginMethodQRScan {
|
||||
if err := s.Store.Cookies.SetStatusWithReason(ctx, cookieID, true, ""); err != nil && s.Logger != nil {
|
||||
if err := repository.SetStatusWithReason(ctx, cookieID, true, ""); err != nil && s.Logger != nil {
|
||||
s.Logger.Warn("成功登录后启用账号失败", "cookie_id", cookieID, "method", method, "err", err)
|
||||
}
|
||||
}
|
||||
@@ -50,13 +55,15 @@ func (s *Server) markSuccessfulLogin(ctx context.Context, cookieID string, userI
|
||||
}
|
||||
|
||||
func (s *Server) addLoginLog(ctx context.Context, cookieID string, userID int64, method, status, failureReason, message string, at int64) {
|
||||
if s.Store == nil || s.Store.LoginLogs == nil {
|
||||
// repository 提供登录日志持久化能力。
|
||||
repository := s.accountLoginRepositoryForServer()
|
||||
if repository == nil {
|
||||
return
|
||||
}
|
||||
if at == 0 {
|
||||
at = time.Now().Unix()
|
||||
}
|
||||
if err := s.Store.LoginLogs.Add(ctx, db.AccountLoginLog{
|
||||
if err := repository.AddLoginLog(ctx, db.AccountLoginLog{
|
||||
CookieID: cookieID,
|
||||
UserID: userID,
|
||||
OwnerID: userID,
|
||||
|
||||
Reference in new issue
Block a user