{"id":15517309,"url":"https://github.com/skx/remotehttp","last_synced_at":"2025-04-23T03:50:58.647Z","repository":{"id":55464608,"uuid":"246865930","full_name":"skx/remotehttp","owner":"skx","description":"Magic wrapper to deny HTTP-requests to to \"local\" resources.","archived":false,"fork":false,"pushed_at":"2020-12-29T10:44:58.000Z","size":38,"stargazers_count":8,"open_issues_count":0,"forks_count":2,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-29T21:51:06.627Z","etag":null,"topics":["go","golang","http","library","security","transport","utility","wrapper"],"latest_commit_sha":null,"homepage":null,"language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/skx.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null},"funding":{"github":"skx","custom":"https://steve.fi/donate/"}},"created_at":"2020-03-12T15:15:43.000Z","updated_at":"2022-10-11T19:06:29.000Z","dependencies_parsed_at":"2022-08-15T01:00:33.671Z","dependency_job_id":null,"html_url":"https://github.com/skx/remotehttp","commit_stats":null,"previous_names":[],"tags_count":6,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/skx%2Fremotehttp","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/skx%2Fremotehttp/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/skx%2Fremotehttp/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/skx%2Fremotehttp/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/skx","download_url":"https://codeload.github.com/skx/remotehttp/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250366685,"owners_count":21418768,"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","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":["go","golang","http","library","security","transport","utility","wrapper"],"created_at":"2024-10-02T10:12:27.668Z","updated_at":"2025-04-23T03:50:58.632Z","avatar_url":"https://github.com/skx.png","language":"Go","readme":"[![GoDoc](https://img.shields.io/static/v1?label=godoc\u0026message=reference\u0026color=blue)](https://pkg.go.dev/github.com/skx/remotehttp)\n[![Go Report Card](https://goreportcard.com/badge/github.com/skx/remotehttp)](https://goreportcard.com/report/github.com/skx/remotehttp)\n[![license](https://img.shields.io/github/license/skx/remotehttp.svg)](https://github.com/skx/remotehttp/blob/master/LICENSE)\n\n# remotehttp\n\nThis repository contains a trivial helper for making secure HTTP-requests with golang.\n\n\n\n# The Problem\n\nImagine you have a service to which users to submit tasks containing references to remote objects (HTTP-URLs).\n\n* For example you might allow users to enter the location of a HTML document.\n* Your service fetches that remote resource, then converts it to PDF, or similar.\n* The results are then shown to the user.\n\nNow imagine what happens if the user supplies URLs such as these, as input to your service:\n\n* http://localhost/server-status\n* http://169.254.169.254/latest/meta-data/\n\nThis package allows you to __prevent__ these inputs from being processed, easily.\n\n\n\n## Using It\n\nSample usage can be found in [remotehttp_example_test.go](remotehttp_example_test.go).\n\n\n## Other considerations\n\nThis wrapper-library only considers the case of `http` and `https` schemas; if you're accepting URIs of your own you should absolutely sanity-check you've not been given something with a `file://`, or `ftp://` prefix (and more!)\n\nOther things you'll want to consider:\n\n* Resource limits such as timeout-handling.\n* Resource limits such as whether to follow redirections, and if so how many.\n\nSteve\n","funding_links":["https://github.com/sponsors/skx","https://steve.fi/donate/"],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fskx%2Fremotehttp","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fskx%2Fremotehttp","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fskx%2Fremotehttp/lists"}