Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add plugin real-ip #115

Draft
wants to merge 2 commits into
base: main
Choose a base branch
from
Draft

Conversation

Strangevy
Copy link

Ⅰ. Describe what this PR did

Add a wasm plugin that the functional equivalent of nginx real_ip module

Ⅱ. Does this pull request fix one issue?

fixes #92

Ⅲ. Why don't you add test cases (unit test/integration test)?

No unit tests yet

Ⅳ. Describe how to verify it

The real IP can be obtained by configuring related attributes according to the README.md

Ⅴ. Special notes for reviews

Check README.md

@CLAassistant
Copy link

CLAassistant commented Dec 29, 2022

CLA assistant check
All committers have signed the CLA.

plugins/wasm-go/extensions/real-ip/main.go Outdated Show resolved Hide resolved
plugins/wasm-go/extensions/real-ip/main.go Outdated Show resolved Hide resolved
plugins/wasm-go/extensions/real-ip/main.go Outdated Show resolved Hide resolved
plugins/wasm-go/extensions/real-ip/main.go Outdated Show resolved Hide resolved
plugins/wasm-go/extensions/real-ip/main.go Outdated Show resolved Hide resolved
plugins/wasm-go/extensions/real-ip/main.go Outdated Show resolved Hide resolved
@Strangevy Strangevy reopened this Feb 2, 2023
host = realIp
}

err = proxywasm.SetProperty([]string{"remote", "address"}, []byte(host))
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This feature is still waiting to be implemented, this PR is temporarily hold

@johnlanni johnlanni marked this pull request as draft February 15, 2023 02:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Implement A wasm plugin that the functional equivalent of nginx real_ip module
5 participants