question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Server version detection

See original GitHub issue

A question for the library’s gurus…


Is there anything within the PostgreSQL connection protocol that would provide in indication as to the server’s version and/or features, without having to execute SELECT version()?

Here’s the thing: I need to auto-replace every SELECT * FROM proc_name() with CALL proc_name() - the new syntax added in PostgreSQL v11, so I need to know what server version we are connected to, without having to execute a separate SELECT version() for it.

Issue Analytics

  • State:open
  • Created 4 years ago
  • Comments:9 (6 by maintainers)

github_iconTop GitHub Comments

2reactions
charmandercommented, Nov 6, 2019

I don’t think any part of pg uses the ParameterStatus startup messages yet, but they are parsed and should be emitted on the connection as a 'parameterStatus' event. server_version is one.

1reaction
charmandercommented, Nov 6, 2019

A custom Client type that extends pg.Client is one way (maybe not the simplest) – you can add the listener in the constructor.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Service and Version Detection | Nmap Network Scanning
Having an accurate version number helps dramatically in determining which exploits a server is vulnerable to. Version detection helps you obtain this ...
Read more >
Version Detection - an overview | ScienceDirect Topics
Detecting Service and Application Versions ... By default, Nmap identifies open ports on the target host and correlates those port numbers with common...
Read more >
Multiple Methods of Performing Web Server Version Detection
Multiple Methods of Performing Web Server Version Detection · 1. Using nmap · 2. Using Metasploit · 3. Using HTTP Headers · 4....
Read more >
Nmap Version Scan, determining the version and available ...
The main reason most sysadmins will run a version scan is to detect security holes or vulnerabilities belonging to outdated or specific software...
Read more >
Apache Version Detection Scanner - Security For Everyone
The Apache HTTP Server Project is an effort to develop and maintain an open-​source HTTP server for modern operating systems including UNIX and...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found