mirror of
https://github.com/fatedier/frp.git
synced 2026-05-15 08:05:49 -06:00
[GH-ISSUE #1927] Aderviser: frps add -list param #1528
Labels
No labels
In Progress
WIP
WaitingForInfo
bug
doc
duplicate
easy
enhancement
future
help wanted
invalid
lifecycle/stale
need-issue-template
need-usage-help
no plan
proposal
pull-request
question
todo
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: github-starred/frp#1528
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @banyet1 on GitHub (Aug 1, 2020).
Original GitHub issue: https://github.com/fatedier/frp/issues/1927
Hello,
FRP is a great work, thanks for your efforts.
Could you add a new feature in fprs to list all the client and port? If that so, we can use the list to do a lot of things, say, DNS auto-update, or send cmd to the client via shell scripts.
Ex: ./frps -list
8000:1.1.1.1:22
8001:1.1.1.2:23
...
Thanks.
@Becods commented on GitHub (Aug 2, 2020):
Hello,
This is my personal opinion:
I think your idea can be implemented through Get Dashboard.
If you have a better way to implement it, welcome to pull requests.
@banyet1 commented on GitHub (Aug 2, 2020):
Hi,
Thanks for the reply, the Dashboard does not have any info about remote IP, I've double-checked. So I don't have clue but edit source code from square one.
@Becods commented on GitHub (Aug 2, 2020):
All right,
Maybe I haven't used the dashboard for a long time.
You may be able to look at the TCP connections that make connections to FRPs.
I hope you will be successful.
@banyet1 commented on GitHub (Aug 2, 2020):
Hi,
Thanks for your replay.
The thing is if you've over 10+clients, so I don't think I can using netstat to identify every connection.
Btw: I think it's not so complicated that add current query connection.
Best.
@fatedier commented on GitHub (Aug 3, 2020):
What's the meaning of ip above? Can you descibe more details about your usage scenarios?
@banyet1 commented on GitHub (Aug 3, 2020):
Hi,
In my case, I've lot of hosts who don't have the static IP address, so I using API update DNS automatically (nobody can remember over 10 IPs but domain names).
So I need to know the current IP and updating DNS automatically (because I know the remote port, so I can identify which domain name should mapping to what exactly IP address).
Best!
@banyet1 commented on GitHub (Aug 3, 2020):
btw:
Ex: ./frps -list
8000:1.1.1.1:22
8001:1.1.1.2:23
remoteport:remoteip:localport.
@fatedier commented on GitHub (Aug 3, 2020):
What the meaning of
remote-ip? IP of frpc?Can you share your example configure files?
@banyet1 commented on GitHub (Aug 3, 2020):
Hi,
Sorry for the delay, here is a sample:
Client fc.ini:
[common]
server_addr = server_ip
server_port = 17000
[SSH]
type = tcp
local_ip = 127.0.0.1
local_port = 22
remote_port = 50000
use_encryption = true
use_compression = true
Server fs.ini:
[common]
bind_port = 17000
dashboard_port = 17500
dashboard_user = admin
dashboard_pwd = password
In this case, I do not know the client's IP (dynamic) only if ssh user@server_ip -p 50000 to logon and "netstat" to check it out. But the server knows which client's IP has been mapping to port 5000, so I need the server to tell me that client's IP without via SSH.
Ex: ./frps -list
50000:client_ip
I need this mapping table.
Thanks.
@fatedier commented on GitHub (Aug 4, 2020):
frp don't care about clinet's IP. Machines running frpc are usually behind the NAT without public IP.
You'd better try DDNS?
@banyet1 commented on GitHub (Aug 4, 2020):
Hi,
The thing is I did have ddns running on NAT host to update DNS(crontab every 30mins), but I want the frps update DNS instead, because if the NAT's IP has changed, the frps will know it at first.
That's more efficient than running ddns on NAT host, that's why I need frps to tell me the IP and port mapping list.
Best.
@fatedier commented on GitHub (Aug 4, 2020):
It's not the scenario supported by frp.
If you use DDNS,your machines are not behind the NAT and have public IPs. You maybe search for other DDNS projects to solve your problem or just write more reliable scripts.
@banyet1 commented on GitHub (Aug 4, 2020):
Hi,
Let me be as clear as possible I can, sorry for some misunderstandings.
The NAT host doesn't have public IP, but the gw has public IP. The frpc running on NAT host connect from gw to frps, and the gw has it's own public IP(PPPOE), it's usually the way the frps works (from frps connect through gw's public IP to NAT host) .
And I'm using commercial DNS API (Godaddy) to update DNS resolver, not some DDNS program.