{"id":22050353,"url":"https://github.com/narrowtux/loppers","last_synced_at":"2025-09-07T14:13:05.839Z","repository":{"id":57518606,"uuid":"97480619","full_name":"narrowtux/loppers","owner":"narrowtux","description":"Validate quoted elixir code against a function whitelist","archived":false,"fork":false,"pushed_at":"2024-06-06T15:09:22.000Z","size":28,"stargazers_count":7,"open_issues_count":3,"forks_count":2,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-08-16T05:27:09.948Z","etag":null,"topics":["ast","elixir","whitelist"],"latest_commit_sha":null,"homepage":null,"language":"Elixir","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/narrowtux.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-07-17T13:40:28.000Z","updated_at":"2024-06-06T15:09:25.000Z","dependencies_parsed_at":"2024-11-30T14:23:53.287Z","dependency_job_id":"6623b1ad-22b4-4e4c-8656-5452de1aabb7","html_url":"https://github.com/narrowtux/loppers","commit_stats":{"total_commits":19,"total_committers":3,"mean_commits":6.333333333333333,"dds":"0.21052631578947367","last_synced_commit":"1dba8cece046e7ac1883bec8c663ce46e68a86d4"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/narrowtux/loppers","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/narrowtux%2Floppers","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/narrowtux%2Floppers/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/narrowtux%2Floppers/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/narrowtux%2Floppers/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/narrowtux","download_url":"https://codeload.github.com/narrowtux/loppers/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/narrowtux%2Floppers/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":274046000,"owners_count":25212982,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-09-07T02:00:09.463Z","response_time":67,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["ast","elixir","whitelist"],"created_at":"2024-11-30T14:23:11.659Z","updated_at":"2025-09-07T14:13:05.798Z","avatar_url":"https://github.com/narrowtux.png","language":"Elixir","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Loppers\n\nA code validator for the Elixir-AST.\n\nIt can operate on both white- and blacklists.\n\n## Basic example:\n```elixir\nquoted = quote do\n  \"hello\"\n  |\u003e String.upcase\n  |\u003e String.pad_leading(4, \"0\")\nend\nwhitelist = Loppers.special_forms ++ [\n  {Kernel, :|\u003e},\n  {String, :upcase},\n  {String, :pad_leading}\n]\n:ok = Loppers.validate(quoted, whitelist: whitelist)\n```\n\n## Features\n\n * Ideally used in combination with `Code.string_to_quoted/2` to check for\n   nasty things in untrusted code.\n * Operate against a whitelist, blacklist or a mix of both (blacklist \u003e whitelist)\n * Works with `alias` and `import` in the code (special handling for that in\n   the `Loppers.Walk` module)\n * Returns the AST-Fragment (including the line number if your compiler provides it)\n   so you can add squiggly lines to the editor at the right place.\n * Whitelist a module with functions with `{Application.Callbacks, :__all__}`\n * Whitelist a module with all child-modules and functions with `{Application.Callbacks, :__submodules_all__}`\n\n\n## Installation\n\nThe package can be installed by adding `loppers` to your list of dependencies\nin `mix.exs`:\n\n```elixir\ndef deps do\n  [{:loppers, \"~\u003e 0.1.2\"}]\nend\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnarrowtux%2Floppers","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnarrowtux%2Floppers","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnarrowtux%2Floppers/lists"}