I used the new https://learning.postman.com/docs/sending-requests/supported-api-frameworks/websocket/ of postman to check a TCP connectivity to a remote host.
Using Test-NetConnection I got to know that the connection is successful.
Test-NetConnection 138.149.1.1 -Port 6021
The connectivity is failing and I am wondering was it due to misplaced port.
I passed the port like this .
Also I tried to send it as a Header parameter and a normal parameter , yet no avail .Any help is appreciated since this is a Beta feature of Postman.
Also I tried below too.
hostname:port
Related
I have testing a grpc service made in golang. The server is running in localhost:50051. If I test with Postman, the application retrieve me a valid response:
Now, I trying to connect with an application, so I am using ngrok to expose my service.
First, I tried with this command:
./ngrok tcp localhost:50051
This is pointing to tcp://0.tcp.ngrok.io:19230, so I entered 0.tcp.ngrok.io:19230 into postman, but nothing happened, only I got an error.
Then, I tried to use a ngrok.yml configuration for the tunnel. This is the file:
Of course, using ./ngrok start grpc, and using the new ngrok tcp connection with postman, the same error occurs.
I don't know what I am doing wrong.
I'm doing the following tutorial of creating tokens on Solana.
https://spl.solana.com/token
and it seems that all requests to Solana devnet are failing
$spl-token create-token
Creating token 2rxgzZ1tk692aZJXDz8NhTkVXQWB396Z3L21nTUYWCFi
error sending request for url (https://api.devnet.solana.com/): error trying to connect: invalid certificate: UnknownIssuer
I'm not so much of an expert when it comes to network, but i thought it was permission issue in firewall as I am currently working on this in corporate environment.
but as I tested with telnet, it doens't seem like a firewall issue
147.28.33.107 is an IP address of Solana devenet network.
telnet 147.28.33.107 80
I have the similar problem but I sorted out by specifying the path to my-keypair.json.
I built a simple Webserver with just the serve function from the std http module. It just redirects a request to a new URL:
import { serve } from "https://deno.land/std#0.120.0/http/server.ts";
serve(req => Response.redirect("https://google.com"))
It works, when I access the server through a browser on my laptop, where the server is running, but when I try to access it on another machine in the same network using the ip-address of my laptop, there simply is no response at all. Is this one of the security features Deno has and if so, how can you deactivate it?
Update:
So I tried looking up the requests I make on my local machine in Wireshark, but when I run the server and send a request, it doesn't show up there. I disabled my Wifi Connection to see if that changes anything and to my surprise, I still got an answer from the server when I sent a request through the browser. I came to the conclusion that the Deno server somehow doesn't serve over the local network which really confuses me. Is there a way to change that behaviour?
This is not related to Deno, but rather the firewall features of your device/router/network or an error in the method that you are using to connect from the other device (typo, network configuration, etc.).
Without additional configuration (by default), serve binds to 0.0.0.0:8000, so — as an example — if your laptop is assigned the local address 192.168.0.100 by your router, you could reach the server at the address http://192.168.0.100:8000.
You might want to do research on SE/NetworkEngineering and elsewhere to determine the cause of the blocked connection.
I'm testing gRPC with .NetCore and looked up for a GUI tool or something that can help me to test my endpoint like testing REST API.
I found a proxy tool: grpc-json-proxy that can be used with Postman tool (also found another GUI tool: grpcox).
Using any tool gives an error like the following when trying to connect to the endpoint:
unable to do request err=[Post
http://localhost:5001/greet.Greeter/SayHello: dial tcp 127.0.0.1:5001:
connect: connection refused]
Any idea what could be the issue?
Most importantly, are you confident the gRPC server is listening on localhost:50051? You may confirm this (on Linux) using:
GRPC="50051"
ss --tcp --listening --processes "sport = :${GRPC}"
NOTE you may need to sudo ss ... to get the process
Or more simply:
telnet localhost 50051
If you get Connected to... that's a good sign
Then, if you're using either of these tools through docker, you'll need to ensure the container can access the host's 50051 port. To do this, run the container use --net=host. This will make the host's port available to the container.
I use grpCurl
My website works fine on my local machine. And it also works fine, when I publish it, and access it over the Internet.
However, when I access it through my company's network (LAN), many requests state in the pending state and they won't return back either successfully, or with error. No IIS logs, no nothing.
After like 5 minutes, the request simply dies. No HTTP response is shown in Chrome's console. I guess it's a network problem. But I don't know how to debug it.
How should I debug this pending state?
This is more a problem for sys-ops than for development but you might need to verify/prove the problem is with the routers and not with your server or computer configuration.
The first tool you need is network analyzer, for this look no further than Wireshark. You'll need administrator permissions on your machine.
Wireshark is intuitive, but has a lot of features, you might want to read a tutorial or two on how to use it.
With Wireshark on your machine you can verify a TCP connection to the server is made or attempted. If you don't know how TCP works, now is the time to learn.
Based on the result you should have your answer of where the problem is:
No TCP SYN sent or sent to wrong IP: problem in your machine. Make sure the server is not redirected to localhost/wrong ip in the hosts file and verify no static routes have been added to your routing table.
Most likely no TCP SYN-ACK: The problem is in the network routing, you might want to install Wireshark on the server and verify the SYN packets are indeed not getting through. Get your sys-ops guys to fix the problem. Probably a misconfigured firewall rule.
Very unlikely: TCP connection established and HTTP request sent to server, but server does not respond. No idea, if the server responds to internet traffic it should respond to your traffic.
By the way if there are no sys-ops guys in your company to fix the problem, get the model of any configurable router between your computer and the server and try asking in Server Fault (or get a consultant).