fix: update drifted citation line numbers
- option_parser.ex: String.to_existing_atom/1 is at line 859, not 855 (line 855 is the String.to_atom clause for allow_nonexistent_atoms) - logger test_helper.exs: capture_log after clause spans lines 57-65, not 57-62 (the 'after' keyword is at line 64, restore at line 65)
This commit is contained in:
@@ -880,7 +880,7 @@ end
|
||||
|
||||
**What they avoid:** Converting untrusted strings to atoms.
|
||||
|
||||
**Source evidence:** `lib/elixir/lib/option_parser.ex:855` — Uses `String.to_existing_atom/1` with the `:switches` allowlist pattern. The only `String.to_atom/1` calls in library code are in compiler/macro contexts where the set is bounded.
|
||||
**Source evidence:** `lib/elixir/lib/option_parser.ex:859` — Uses `String.to_existing_atom/1` with the `:switches` allowlist pattern. The only `String.to_atom/1` calls in library code are in compiler/macro contexts where the set is bounded.
|
||||
|
||||
**Why it's bad:** Atoms are never garbage collected. User-controlled atom creation is a denial-of-service vector (1,048,576 atom limit by default).
|
||||
|
||||
|
||||
Reference in New Issue
Block a user