diff --git a/tools/clang/scripts/build.py b/tools/clang/scripts/build.py
index 92b5870..4b3346b 100755
--- a/tools/clang/scripts/build.py
+++ b/tools/clang/scripts/build.py
@@ -233,6 +233,31 @@
     f.write('group: files\n')
 
 
+def AddOpenSSLToEnv(build_mac_arm):
+  """Download and build OpenSSL, and add to OPENSSL_DIR."""
+  ssl_dir = os.path.join(LLVM_BUILD_TOOLS_DIR, 'openssl-openssl-3.0.7')
+  ssl_install_dir = f'{ssl_dir}/install'
+  if os.path.exists(ssl_dir):
+    RmTree(ssl_dir)
+  zip_name = 'openssl-3.0.7.tar.gz'
+  DownloadAndUnpack(CDS_URL + '/tools/' + zip_name, LLVM_BUILD_TOOLS_DIR)
+  os.chdir(ssl_dir)
+  args = [f'--prefix={ssl_install_dir}', f'--openssldir={ssl_install_dir}']
+  if sys.platform == 'darwin':
+    if build_mac_arm:
+      RunCommand(['./Configure', 'darwin64-arm64-cc'] + args)
+    else:
+      RunCommand(['./Configure', 'darwin64-x86_64-cc'] + args)
+  else:
+    print("Building OpenSSL is only supported on Mac as it's "
+          "already present elsewhere.")
+    sys.exit(1)
+  RunCommand(['make'])
+  RunCommand(['make', 'install'])
+  os.environ['OPENSSL_DIR'] = ssl_install_dir
+  return ssl_install_dir
+
+
 def AddZlibToPath():
   """Download and build zlib, and add to PATH."""
   zlib_dir = os.path.join(LLVM_BUILD_TOOLS_DIR, 'zlib-1.2.11')
diff --git a/tools/clang/scripts/update.py b/tools/clang/scripts/update.py
index 413f125c..87fdb9577 100755
--- a/tools/clang/scripts/update.py
+++ b/tools/clang/scripts/update.py
@@ -35,7 +35,7 @@
 # https://chromium.googlesource.com/chromium/src/+/main/docs/updating_clang.md
 # Reverting problematic clang rolls is safe, though.
 # This is the output of `git describe` and is usable as a commit-ish.
-CLANG_REVISION = 'llvmorg-16-init-14635-ga650f2ec'
+CLANG_REVISION = 'llvmorg-16-init-17653-g39da55e8'
 CLANG_SUB_REVISION = 1
 
 PACKAGE_VERSION = '%s-%s' % (CLANG_REVISION, CLANG_SUB_REVISION)