Commit 2777b89
Seguranca: escapa HTML no PDF, protege CSV e ajustes do Advisor
- exportarPDF/htmlTabela: escapa valores (escHtml) antes de escrever no
document.write da janela de impressao. Nomes de categoria/centro (criados
pelo usuario e pela IA do Telegram) iam sem escapar -> HTML/JS injection
no mesmo dominio do app (risco de roubo do token de sessao no localStorage).
- exportarExcel: protegerCsv prefixa ' em celulas que comecam com = + @
(CSV formula injection), preservando numeros negativos.
- Nova migration seguranca_advisor.sql: fixa search_path de set_updated_at e
revoga EXECUTE publico das funcoes de gatilho (rodar no SQL Editor).
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>1 parent b75a818 commit 2777b89
2 files changed
Lines changed: 86 additions & 5 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
414 | 414 | | |
415 | 415 | | |
416 | 416 | | |
| 417 | + | |
| 418 | + | |
| 419 | + | |
| 420 | + | |
| 421 | + | |
| 422 | + | |
| 423 | + | |
| 424 | + | |
| 425 | + | |
| 426 | + | |
| 427 | + | |
417 | 428 | | |
418 | 429 | | |
419 | 430 | | |
420 | 431 | | |
421 | | - | |
| 432 | + | |
422 | 433 | | |
423 | 434 | | |
424 | 435 | | |
| |||
434 | 445 | | |
435 | 446 | | |
436 | 447 | | |
| 448 | + | |
| 449 | + | |
| 450 | + | |
| 451 | + | |
| 452 | + | |
| 453 | + | |
| 454 | + | |
| 455 | + | |
| 456 | + | |
437 | 457 | | |
438 | 458 | | |
439 | 459 | | |
440 | 460 | | |
441 | | - | |
| 461 | + | |
442 | 462 | | |
443 | 463 | | |
444 | 464 | | |
| |||
1950 | 1970 | | |
1951 | 1971 | | |
1952 | 1972 | | |
1953 | | - | |
1954 | | - | |
1955 | | - | |
| 1973 | + | |
| 1974 | + | |
| 1975 | + | |
1956 | 1976 | | |
1957 | 1977 | | |
1958 | 1978 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
0 commit comments