Coder Social home page Coder Social logo

Comments (3)

Chithesus avatar Chithesus commented on June 25, 2024

@jfb8856606 老铁, how does fstack judge which port to support? I found it set a bitmap for the port. is it a problem of aws?

from f-stack.

Chithesus avatar Chithesus commented on June 25, 2024

config.ini:

[kni]
type=0
enable=1
method=accept
;The format is same as port_list
tcp_port=20
udp_port=53


ff_bind :

struct sockaddr_in my_addr;
bzero(&my_addr, sizeof(my_addr));
my_addr.sin_family = AF_INET;
my_addr.sin_port = htons(10000); // top:20000
my_addr.sin_addr.s_addr = htonl(INADDR_ANY);
int ret = ff_bind(client_socket, (struct linux_sockaddr *)&my_addr, sizeof(my_addr));
if (ret < 0) {
printf("ff_bind failed, sockfd:%d, errno:%d, %s\n", client_socket, errno, strerror(errno));
exit(1);
}

// loop3(NULL);

if (ff_connect(client_socket, (struct linux_sockaddr *)&server_addr, sizeof(server_addr)) < 0)
{
    printf("connect failed: %s\n", strerror(errno));
}
else {
    printf("connect success\n");
}

from f-stack.

Chithesus avatar Chithesus commented on June 25, 2024

I run "tcpdump -i any -XSs0 " to catch all the message between client and server; I found client response to SYN_ACK message from server sometimes(client binding to certain ports can success to connect to server, but other ports fail to connect); i am sure server is ok

from f-stack.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.