postgrest-js VS pgsodium

Compare postgrest-js vs pgsodium and see what are their differences.

postgrest-js

Isomorphic JavaScript client for PostgREST. (by supabase)

pgsodium

Modern cryptography for PostgreSQL using libsodium. (by michelp)
SurveyJS - Open-Source JSON Form Builder to Create Dynamic Forms Right in Your App
With SurveyJS form UI libraries, you can build and style forms in a fully-integrated drag & drop form builder, render them in your JS app, and store form submission data in any backend, inc. PHP, ASP.NET Core, and Node.js.
surveyjs.io
featured
InfluxDB - Power Real-Time Data Analytics at Scale
Get real-time insights from all types of time series data with InfluxDB. Ingest, query, and analyze billions of data points in real-time with unbounded cardinality.
www.influxdata.com
featured
postgrest-js pgsodium
11 15
923 509
1.5% -
7.5 4.4
17 days ago 9 days ago
TypeScript C
MIT License GNU General Public License v3.0 or later
The number of mentions indicates the total number of mentions that we've tracked plus the number of user suggested alternatives.
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.

postgrest-js

Posts with mentions or reviews of postgrest-js. We have used some of these posts to build our list of alternatives and similar projects. The last one was on 2023-12-02.
  • Ask HN: What are some unpopular technologies you wish people knew more about?
    56 projects | news.ycombinator.com | 2 Dec 2023
    At one point, I really thought it was used in Supabase. But I guess they only wrote the js wrapper for it. https://github.com/supabase/postgrest-js

    Came here to mention Hasura as well (not sure of it's popularity though) https://hasura.io/graphql/database/postgresql

  • Why supabase client don't introduce min, max and count functions
    1 project | /r/Supabase | 29 Apr 2023
    Min/Max looks like it still has to be done via RPC (with sample code here) https://github.com/supabase/postgrest-js/issues/206
  • Completely baffled about async call.
    1 project | /r/learnjavascript | 6 Apr 2023
  • Why to use Supabase instead of Prisma (or any other ORM) with a Postgres DB?
    3 projects | /r/Supabase | 3 Feb 2023
    There's nothing wrong with this and they're pretty open about it. But the SDK they provide for direct database operations is the weakest of the ones I've used, when it should be the strongest I think. It leverages PostgREST which is a tool for auto generating REST APIs from schemas. From the README: "The goal of this library is to make an "ORM-like" restful interface."
  • Should I use Prisma to get data or Supabase itself to get data
    1 project | /r/Supabase | 24 Jan 2023
    Looks like there's an open github issue that might answer some of your questions: https://github.com/supabase/postgrest-js/issues/303
  • Supabase secrets management available in beta
    6 projects | news.ycombinator.com | 16 Dec 2022
    I think it’s great too. I wish they would shore up some of their existing releases though. Probably most notably, the ability to query aggregates via the officially supported route is missing: https://github.com/supabase/postgrest-js/issues/206

    The workarounds suggested are not ergonomic for most use cases and it feels pretty out of place for such basic functionality to be missing in what otherwise feels like a pretty full featured product.

    Their Realtime product is another example of something that languishes while new features get launched.

  • Need help looking for a tool
    1 project | /r/nocode | 20 Sep 2022
    I haven't completely understood what you are looking for but I think Supabase could be potential useful alternative backend for you supabase.io ?
  • How I Built Skillbit: Linktree, but for Your Skills
    2 projects | dev.to | 1 Sep 2022
    I used postgrest-js to communicate with my PostgREST endpoint. The library is easy to use and does everything for you.
  • Supabase-JS v2
    4 projects | news.ycombinator.com | 16 Aug 2022
    yes you're right. The JS library is a thin wrapper around PostgREST's API (https://github.com/supabase/postgrest-js)

    Supabase now offers a few more features which integrate with the Postgres database - File Storage (s3), Authentication, Deno Functions, and Realtime (database change listeners). Each of these services is a standalone server and each has a corresponding JS library.

    "supabase-js" wraps up the modular JS libraries into a single library for convenience

  • Supabase May 21: Apple and Twitter Logins, Supabase Grid, Go and Swift Libraries
    3 projects | news.ycombinator.com | 2 Jun 2021
    * Swift Libraries are now underway thanks to @satishbabariya [2]

    We still have a long way to go for mobile support, but the Apple logins is a big one. If you ship an app to the App Store with any third-party logins, you're required to enable Apple logins as well. While this sounds like a bit of over-reach, it's actually quite cool - if you use Apple login they obfuscate your email so that the 3rd party app don't get access to your personal data. Quite nice!

    [0] CSV: https://github.com/supabase/postgrest-js/pull/187

pgsodium

Posts with mentions or reviews of pgsodium. We have used some of these posts to build our list of alternatives and similar projects. The last one was on 2024-01-31.
  • Macaroons Escalated Quickly
    4 projects | news.ycombinator.com | 31 Jan 2024
    I like the "solve the now" perspective here, and having code examples is very helpful to understand some of the rational behind the approach. Having read your previous "tedious survey"[0] post on various token formats, I generally agree with a lot of your conclusions. Curious though about your thought process wrt macaroons vs biscuits.

    To me the one major downside of macaroons has always been the single shared root symmetric key. Many use cases are addressed by third party attenuation, but then there are the problems like key rotation, having to do online verification, no built in encryption, no peer-to-peer support through an "untrusted" fly.io, and no third party token verification without decryption like in signcryption[1] schemes. Of course this is traded off by having to do PK issuance and management so I can see the simplicity of it.

    Is fly.io scoping this pretty hard to just auth tokens with third party attenuation, or do you see further development and maybe moving to other token systems like biscuit when/if the need arises to address those known issues?

    fwiw I've done a bit of research work myself on a token format using signcryption [2] where I explored addressing some of these ideas (but not the attenuation side of it yet, which I get is a big deal here).

    [0] https://fly.io/blog/api-tokens-a-tedious-survey/

    [1] https://github.com/jedisct1/libsodium-signcryption

    [2] https://github.com/michelp/pgsodium/blob/feat/signcryption-t...

  • PostgreSQL Encryption: The Available Options
    4 projects | news.ycombinator.com | 6 Nov 2023
    pg_sodium [1] is another great options for transparent (column level!) encryption. Its integrated with Supabase [2] if you want to give it a try

    [1] https://github.com/michelp/pgsodium

  • Update - I built an app that analyses your worries and challenges your thoughts, looking for feedback
    2 projects | /r/CBTpractice | 16 May 2023
    Yes! Concerning privacy: The entries are saved in Supabase and encrypted with pgsodium. I think there's a lot more to privacy, though – currently working on other safety measures like anonymization that I'll include before scaling. What sets the app apart: I have built the app specifically to integrate therapy tactics into your daily life and to make them a habit (e. g. if you talk to ChatGPT or Wysa it tells you what tactics to integrate and learn about them, with my app you actually integrate them) => less about learning, more about doing.
  • I built an app that helped me move on by teaching me how to react differently to my thoughts.
    2 projects | /r/heartbreak | 13 Apr 2023
    Valid concern. The entries are saved in Supabase and encrypted with pgsodium. I think there's a lot more to privacy, though – currently working on other safety measures like anonymization that I'll include before scaling and releasing the app to the broader public. Still looking for testers; sent you a DM. Let me know if you're in!
  • pgsodium- Modern cryptography for PostgreSQL using libsodium.
    1 project | /r/CKsTechNews | 29 Mar 2023
  • Supabase secrets management available in beta
    6 projects | news.ycombinator.com | 16 Dec 2022
    > Is Vault something that can handle this without getting into my app code? Basically, if i gave a someone root access to my supabase instance is that encrypted data safe?

    The answer is slightly offset from your question, so let me start by pointing out that the Vault is about Encrypted Data At Rest. This is mentioned in the docs and in the blog and video, but it's something that I like to always mention first in discussions. The main purpose of the Vault is to store your data encrypted, so that it's encrypted on disk, and in backups. In SQL the decrypted secrets are available to you, because that's where you are using them and encrypted data must be decrypted to be useful.

    If someone roots access to your database, then yes they can access the decrypted secrets through the view. This is by design, the secrets must be decrypted to be useful in query code. This risk is similar to someone rooting your application code, they will see decrypted secrets via your environment key, so no it won't protect you against anyone rooting processes in your stack that need useful access to secrets and it's not meant to. Like all security you must take a layered approach, the Vault is just one storage level layer strategy.

    One big difference from the env var approach though is that the key Supabase uses to encrypt your secrets with the Vault is stored outside the database, it is inaccessible to SQL, which is an enhancement over sticking the raw key into an environment variable or a table that is accessible to your application. Instead of revealing the raw key, pgsodium has a feature called [Server Key Management](https://github.com/michelp/pgsodium#server-key-management) where you do not have access to the raw key, but instead reference keys by an key identifier. It is safe to store this identifier alongside the data it encrypts. The raw key itself is never stored. I'm very intentionally overusing the word "store" here, because that's specifically the layer of security that the Vault provides.

  • Supabase Vault
    1 project | news.ycombinator.com | 20 Aug 2022
    The article links directly to here, which may answer your question:

    https://github.com/michelp/pgsodium#server-key-management

  • Encrypting data for a Finance App
    1 project | /r/Supabase | 8 Jul 2022
  • How do I encrypt data before sending it to the database?
    2 projects | /r/reactjs | 3 Feb 2022
  • Show HN: Pgsodium – A Crytographic PostgreSQL Extension
    4 projects | news.ycombinator.com | 10 Jan 2022
    Hey HN, I shared an earlier prototype version of pgsodium but I just released 2.0 and felt this could be a good opportunity to share some updates!

    [pgsodium](https://github.com/michelp/pgsodium) 2.0.0 is a postgres extension that uses the [libsodium](https://doc.libsodium.org/) library to provide high-performance, modern cryptography support for PostgreSQL 10+.

    2.0.0 includes a ton of new feature and a few bug-fixes:

    * Support for [XChaCha20-SIV](https://github.com/jedisct1/libsodium-xchacha20-siv) deterministic nonce-free encryption, this is useful for one-time workflows sacrificing a bit of speed and larger key size without worrying about nonce-handling issues.

What are some alternatives?

When comparing postgrest-js and pgsodium you can also consider the following projects:

nuxt3-supabase - Nuxt 3 module and composables for Supabase.

libsodium-xchacha20-siv - Deterministic/nonce-reuse resistant authenticated encryption scheme using XChaCha20, implemented on libsodium.

solid-supabase - A simple wrapper around Supabase.js to enable usage within Solid.

libsodium.js - libsodium compiled to Webassembly and pure JavaScript, with convenient wrappers.

gotrue-swift - A Swift client library for GoTrue.

libsodium-signcryption - Signcryption using libsodium.

postgrest-go - Isomorphic Go client for PostgREST. (Now Updating)

vault - Extension for storing encrypted secrets in the Vault

vue-supabase - A supa simple wrapper around Supabase.js to enable usage within Vue.

OpenSSL - TLS/SSL and crypto library

flarebase-auth - Firebase/Admin Auth Javascript Library for Cloudflare Workers

supabase - The open source Firebase alternative.