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

[Feature requests] Send Commands To All Clients At Once #6

Closed
zero77 opened this issue Jan 11, 2019 · 12 comments
Closed

[Feature requests] Send Commands To All Clients At Once #6

zero77 opened this issue Jan 11, 2019 · 12 comments
Assignees
Labels
enhancement New feature or request

Comments

@zero77
Copy link

zero77 commented Jan 11, 2019

Can you please add support for sending commands to all clients at once.
Thanks

@WangYihang
Copy link
Owner

@zero77 Got it, I will add this feature to TODO list. thank you for reporting

@zero77
Copy link
Author

zero77 commented Jan 14, 2019

Thanks

@zero77
Copy link
Author

zero77 commented Jan 22, 2019

@WangYihang
Is Platypus still being developed.

@WangYihang
Copy link
Owner

WangYihang commented Jan 22, 2019

@zero77 Yes, it will, I have been busy these days, so the development will be delayed. If you are willing to help to develop, feel free to create pull requests.

@WangYihang
Copy link
Owner

And, the feature you mentioned, that can be implemented by Switching meta command.
Every single client has a field Interacting which indicate the server should send hacker input to the client or not.

>> List
2019/01/22 15:57:11 Listing 1 servers
[a4c0705d05da83e09af1e15ada602af1] 0.0.0.0:4444 (1 online clients) (started at: 18 seconds ago)
	[79809a986dd1c6e38850002f4eb52deb] tcp://127.0.0.1:46536 (connected at: 4 seconds ago) [false]

the last field [false] means hacker input will not be dispatched to this client
so if you want to send single command to all of the clients, all you need to do is make the client Switched On and use DataDispatcher to send the command to all clients which is Switched On.

Example

>> List
2019/01/22 15:59:29 Listing 1 servers
[a4c0705d05da83e09af1e15ada602af1] 0.0.0.0:4444 (3 online clients) (started at: 2 minutes ago)
	[79809a986dd1c6e38850002f4eb52deb] tcp://127.0.0.1:46536 (connected at: 2 minutes ago) [false]
	[c67f1997275fa9a0c1e15efc250a21df] tcp://127.0.0.1:46566 (connected at: 21 seconds ago) [false]
	[f13c0c8ba0301a163e78720c7ffd916c] tcp://192.168.1.7:45462 (connected at: 4 seconds ago) [false]
>> Switching f1
2019/01/22 15:59:36 [false->true] [f13c0c8ba0301a163e78720c7ffd916c] tcp://192.168.1.7:45462 (connected at: 11 seconds ago) [false]
>> List
2019/01/22 15:59:37 Listing 1 servers
[a4c0705d05da83e09af1e15ada602af1] 0.0.0.0:4444 (3 online clients) (started at: 2 minutes ago)
	[79809a986dd1c6e38850002f4eb52deb] tcp://127.0.0.1:46536 (connected at: 2 minutes ago) [false]
	[c67f1997275fa9a0c1e15efc250a21df] tcp://127.0.0.1:46566 (connected at: 29 seconds ago) [false]
	[f13c0c8ba0301a163e78720c7ffd916c] tcp://192.168.1.7:45462 (connected at: 12 seconds ago) [false]
>> DataDispatcher 
Input command: ls
2019/01/22 15:59:44 Executing on [f13c0c8ba0301a163e78720c7ffd916c] tcp://192.168.1.7:45462 (connected at: 20 seconds ago) [false]: ls
4
2019/01/22 15:59:44 Execution finished, 1 node DataDispatcherd
>>  

@zero77
Copy link
Author

zero77 commented Jan 22, 2019

Thanks for your reply, i hope i did not sound pushy.
But, i was wondering if Platypus has stopped being developed, due to the lack of bugs and recent activity.

Also, i will have a look at what you suggested but, i have never used go before.

@WangYihang
Copy link
Owner

Platypus will not stop developing. I need to prepare my postgraduate entrance exam in 2019, so I may not develop it this year, and I will continue to develop after the exam is over.

@zero77
Copy link
Author

zero77 commented Jan 25, 2019

I need to prepare my postgraduate entrance exam in 2019

Yes, i appreciate how time consuming and difficult that can be, good luck.
When i have had time to learn enuf go i will attempt some of the to do list.

@WangYihang
Copy link
Owner

@zero77 Cool, feel free to create pull requests~ 😄

@WangYihang WangYihang self-assigned this Mar 27, 2019
@WangYihang WangYihang added the enhancement New feature or request label Mar 27, 2019
@EddieIvan01
Copy link
Contributor

Hey, I have some questions. The List command's output‘s last field is Interactive field:

>> List
[79809a986dd1c6e38850002f4eb52deb] tcp://127.0.0.1:46536 (connected at: 2 minutes ago) [false]



fmt.Sprintf("[%s] %s://%s (connected at: %s) [%t]", c.Hash, addr.Network(), addr.String(), humanize.Time(c.TimeStamp), c.Interactive)

Should it be the Group instead of Interactive?
In codes, the Interactive field only means if the node is in interactive mode, it's set to true at the beginning of the Interactive command then be set back to false to false at the end, so I can never see the field is false in List command's output
And the Switching set client.Group = !client.Group, the group field means whether dispath command to this client.
If it's a typo? And I think the filed name Group is not clear enough

@WangYihang
Copy link
Owner

Yes! You are right! It is a typo I think, I'll fix it next week, thank you for reporting. 😄 @EddieIvan01

@WangYihang
Copy link
Owner

This issue will be closed since the original problem is solved.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants