Please fill out the fields below so we can help you better. Note: you must provide your domain name to get help. Domain names for issued certificates are all made public in Certificate Transparency logs (e.g. crt.sh | example.com), so withholding your domain name here does not increase secrecy, but only makes it harder for us to provide help.
My domain is: asset.money
I ran this command: I ran a command for setting Telegram bot webhook. This worked fine but when I ran the command to getWebHookInfo I got an error. The Telegram bot is not being able to use the webhook to access the server endpoint at asset.money/telegram-webhook.
It produced this output: After using getWebHookInfo I get the following error:
My web server is (include version): Apache Server (Latest version)
The operating system my web server runs on is (include version): Linux Ubuntu (Latest)
My hosting provider, if applicable, is: AWS
Could someone please help me understand if this is an error caused due to not having a self-signed SSL certificate, and if so how do I make my current certificate self-signed and if there is any work around or security issues I must take into consideration while doing the same?
that doesn't look like an error to me.
The webhook was working fine before this message started getting displayed. If you could help me out as to what could be the possible reason for the webhook to stop working, I would most definitely appreciate that
where does that message appear?
This message appears when I use the getWebHookInfo for the Telegram bot that I created. I use a GET request so it gets displayed on the browser.
The get request endpoint is:
Yup it was working fine until yesterday. Today when I tried giving commands to the bot it didnt reply so I checked the webhook status to which I received the above reply.
I set up the bot on 2nd April 2022 and received proper messages till yesterday. Today it stopped working. I also reset the webhook but that too didn't solve the issue.
Did you edit some configuration on your webserver? I get an html page on the webhook endpoint.
Nope, the configuration is unchanged, the webserver redirects the requests to the backend API running on port 8000 on the server. This is also a POST endpoint, therefore you get an HTML page since we have created the frontend in a such a way that if a GET request is sent to a non-existent route, it will send a NGMI or Not found static html page in response.
We have made use of build folder in React using npm run build, then add the build folder to Node.js app's root folder and serve these static files directly from the build folder whenever anyone tries to visit asset.money. The node app runs on port 8000 on the server.
ok, try sending a post request yourself. (I have no idea of the right payload)
Are you sure about this?\
% openssl s_client -connect asset.money:8000
140202948429184:error:0200206E:system library:connect:Connection timed out:../crypto/bio/b_sock2.c:110:
140202948429184:error:2008A067:BIO routines:BIO_connect:connect error:../crypto/bio/b_sock2.c:111:
Actually, the payload is sent by the Telegram bot to the server end point and it contains the updates to the bot, the payload consists of the chatid where the message has been sent to the bot, the commands in the message, the message txt. What the endpoint does is that it sees what command has been sent, then according the command a database check is made and user is added or removed from a subscription list. The commands are /start or /stop. For each command, there is a message that the telegram bot sends to the user. For example, if the user is subscribing for the first time a welcome message is sent, if the user wants to leave the subscription a goodbye message is sent and if an already subscribed user tries to subscribe again, it send a message saying you have already subscribed.
Could I know what this error means? I have seen such an error for the first time
I'm asking you to impersonate the telegram server and send a request to your webhook.
It means nothing is responding to me on port 8000. Is your app running? Is your firewall allowing it? Are you filtering some countries?
Your firewall is not allowing it indeed, if it's running:
% nmap -p1-65532 asset.money
Starting Nmap 7.92 ( https://nmap.org ) at 2022-04-08 15:08 CEST
Nmap scan report for asset.money (188.8.131.52)
Host is up (0.13s latency).
rDNS record for 184.108.40.206: ec2-18-119-100-180.us-east-2.compute.amazonaws.com
Not shown: 65529 filtered tcp ports (no-response)
PORT STATE SERVICE
22/tcp open ssh
80/tcp open http
443/tcp open https
Nmap done: 1 IP address (1 host up) scanned in 215.70 seconds
Is that all internal to the server or can port 8000 be accessed from the Internet?
Let me check with my senior and get back to you with this, actually I am not in control of the server at the moment. Although as long as I remember such filtering according to countries etc is not present. Also the app is running fine on https://asset.money. If so I might have to see for any issues in the server configurations.
The get requests can be accessed on port 8000 from the Internet. The post requests will result in getting a static Not found page since there is no corresponding GET route for the POST route