{"id":14976965,"url":"https://github.com/hillu/go-ntdll","last_synced_at":"2025-06-30T02:05:18.801Z","repository":{"id":38905111,"uuid":"68536240","full_name":"hillu/go-ntdll","owner":"hillu","description":"Go interface to NTDLL functions","archived":false,"fork":false,"pushed_at":"2024-04-18T17:39:03.000Z","size":286,"stargazers_count":74,"open_issues_count":0,"forks_count":12,"subscribers_count":5,"default_branch":"master","last_synced_at":"2025-04-08T12:50:12.068Z","etag":null,"topics":["go","golang","ntdll","windows"],"latest_commit_sha":null,"homepage":null,"language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-2-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/hillu.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":"security.go","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null},"funding":{"github":"hillu"}},"created_at":"2016-09-18T17:25:59.000Z","updated_at":"2025-03-28T18:39:49.000Z","dependencies_parsed_at":"2024-06-18T16:51:42.394Z","dependency_job_id":"0f9bedd9-1667-48a2-bc85-dc817fb829c3","html_url":"https://github.com/hillu/go-ntdll","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/hillu/go-ntdll","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hillu%2Fgo-ntdll","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hillu%2Fgo-ntdll/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hillu%2Fgo-ntdll/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hillu%2Fgo-ntdll/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/hillu","download_url":"https://codeload.github.com/hillu/go-ntdll/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hillu%2Fgo-ntdll/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":262697256,"owners_count":23349891,"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","ntdll","windows"],"created_at":"2024-09-24T13:54:45.772Z","updated_at":"2025-06-30T02:05:18.780Z","avatar_url":"https://github.com/hillu.png","language":"Go","funding_links":["https://github.com/sponsors/hillu"],"categories":[],"sub_categories":[],"readme":"Go interface to NTDLL functions\n===============================\n\n[![GoDoc](https://godoc.org/github.com/hillu/go-ntdll?status.svg)](https://godoc.org/github.com/hillu/go-ntdll)\n[![Go Report Card](https://goreportcard.com/badge/github.com/hillu/go-ntdll)](https://goreportcard.com/report/github.com/hillu/go-ntdll)\n\nThis package makes selected `NTDLL` functions directly available in Go\nprograms. At the moment, types and functions for accessing kernel\nobjects and the Registry are included. The goal is to, eventually,\ncover all available functions.\n\nNote\n----\n\nPlease do not consider this code, particularly the autogenerated code,\nas stable. Identifiers names may still be subject to change.\n\nBasic functions, types\n----------------------\n\nNTDLL functions usually return an `NTSTATUS`, this is mapped into an\n`NtStatus` type (underlying kind: `uint32`). Strings are usually\npassed around as `UNICODE_STRING`, there is a type `UnicodeStringType`\nfor that.\n\nVariable-Sized Arrays\n---------------------\n\nStructs that contain fields that are arrays with one (or\n`ANYSIZE_ARRAY`) elements. For those fields, getters that return a\nslice and setters that fill the array from a slice are generated.\n\nExample:\n``` c\ntypedef struct _FILE_NAME_INFORMATION {\n  ULONG FileNameLength;\n  WCHAR FileName[1];\n} FILE_NAME_INFORMATION, *PFILE_NAME_INFORMATION;\n```\nis turned into\n``` go\ntype FileNameInformationT struct {\n\tFileNameLength uint32\n\tFileName       [1]uint16\n}\n```\nand associated methods\n``` go\nfunc (t *FileNameInformationT) FileNameSlice(size int) []uint16\nfunc (t *FileNameInformationT) SetFileNameSlice(s []uint16)\n```\n\nExtending\n---------\n\nFunction signatures and structure definitions are generated from\nheader file snippets as found in the MSDN. The transformation code can\nbe found in `mkcode.go`, it probably has bugs and does not cover all\ncases.\n\nTo add more structures or function stubs or enumeration types, just\nfind the appropriate definition on MSDN and copy them into block\ncomments, prefixed by `type:`, `func:`, or `enum:`, respectively. `go\ngenerate` can then be used to regenerate the `*_generated.go` files\ncontaining structure definitions and the glue code around\n`golang.org/x/sys/windows`.\n\nLicense\n-------\n\nCopyright (C) 2016-2022  Hilko Bengen \u003cbengen@hilluzination.de\u003e\n\nAll rights reserved.\n\nRedistribution and use in source and binary forms, with or without\nmodification, are permitted provided that the following conditions are met:\n\n* Redistributions of source code must retain the above copyright notice, this\n  list of conditions and the following disclaimer.\n\n* Redistributions in binary form must reproduce the above copyright notice,\n  this list of conditions and the following disclaimer in the documentation\n  and/or other materials provided with the distribution.\n\nTHIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS \"AS IS\"\nAND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE\nIMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE\nDISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE\nFOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL\nDAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR\nSERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER\nCAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,\nOR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE\nOF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhillu%2Fgo-ntdll","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhillu%2Fgo-ntdll","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhillu%2Fgo-ntdll/lists"}