TSGET(1ossl)
π TSGET(1ossl) β the OpenSSL time-stamping HTTP/HTTPS client, bestie edition π
okay so this is tsget, from the OpenSSL manual (openssl section 1, if we're being fancy) π
β¨ NAME β¨
tsget β Time Stamping HTTP/HTTPS client. that's it, that's the whole vibe. she sends timestamp requests over the network and saves what comes back π
π¦ SYNOPSIS π¦
tsget -h server_url [-e extension] [-o output] [-v] [-d] [-k
private_key.pem] [-p key_password] [-c client_cert.pem] [-C
CA_certs.pem] [-P CA_path] [-r files] [-g EGD_socket] [request ...]
π DESCRIPTION π
so here's the tea β β this command sends a timestamp request, exactly as specified in RFC 3161, to a timestamp server over HTTP or HTTPS, and stores the timestamp response in a file. that's her whole job, and she does it flawlessly.
but β and this is important, bestie β she cannot be used for creating the requests and verifying the responses. for that you have to use openssl-ts(1). no cap. she's the messenger, not the message-maker π§
the iconic part: this command can send several requests to the server without closing the TCP connection if more than one request is specified on the command line. efficiency queen π
for each timestamp request, she sends this exact HTTP request:
POST url HTTP/1.1
User-Agent: OpenTSA tsget.pl/<version>
Host: <host>:<port>
Pragma: no-cache
Content-Type: application/timestamp-query
Accept: application/timestamp-reply
Content-Length: length of body
...binary request specified by the user...
and she expects a response of type application/timestamp-reply, which gets written to a file without any interpretation. she doesn't read it, she doesn't judge it, she just delivers π¬
πΈ OPTIONS πΈ
-h server_urlβ the URL of the HTTP/HTTPS server that's listening for timestamp requests. this one's basically required, it's giving main character energy.-e extensionβ if you didn't pass-o, this argument specifies the extension of the output files. the base name of the output file will be the same as those of the input files. default extension is.tsr. (optional)-o outputβ this option can only be specified when just one request is sent to the server. the timestamp response will be written to the given output file.-means standard output. in case of multiple timestamp requests, or if you just don't pass this argument, the names of the output files will be derived from the names of the input files plus the default or specified extension argument. (optional)-vβ the name of the currently processed request is printed on standard error. little progress update, we love to see it. (optional)-dβ switches on verbose mode for the underlying perl moduleWWW::Curl::Easy. you can see detailed debug messages for the connection. she's telling you everything π (optional)-k private_key.pemβ (HTTPS) for certificate-based client authentication over HTTPS,private_key.pemmust contain the private key of the user. the private key file can optionally be protected by a passphrase. the-coption must also be specified. (optional)-p key_passwordβ (HTTPS) specifies the passphrase for the private key specified by the-kargument. if this option is omitted and the key is passphrase protected, it will be prompted for. so she'll just ask you, politely π (optional)-c client_cert.pemβ (HTTPS) for certificate-based client authentication over HTTPS,client_cert.pemmust contain the X.509 certificate of the user. the-koption must also be specified. if this option is not specified, no certificate-based client authentication will take place. (optional)-C CA_certs.pemβ (HTTPS) the trusted CA certificate store. the certificate chain of the peer's certificate must include one of the CA certificates specified in this file. either option-Cor option-Pmust be given in case of HTTPS. (optional)-P CA_pathβ (HTTPS) the path containing the trusted CA certificates to verify the peer's certificate. the directory must be prepared withopenssl-rehash(1). either option-Cor option-Pmust be given in case of HTTPS. (optional)-r filesβ see "Random State Options" inopenssl(1)for more information. that's the whole description, go read the other page bestie π«Ά-g EGD_socketβ the name of an EGD socket to get random data from. (optional)request ...β list of files containing RFC 3161 DER-encoded timestamp requests. if no requests are specified, only one request will be sent to the server and it will be read from the standard input. (optional)
π ENVIRONMENT VARIABLES π
the TSGET environment variable can optionally contain default arguments. the content of this variable is added to the list of command line arguments. it's like a little pre-game snack for your flags π
π EXAMPLES π
the examples below presume that file1.tsq and file2.tsq contain valid timestamp requests, tsa.opentsa.org listens at port 8080 for HTTP requests and at port 8443 for HTTPS requests, and the TSA service is available at the /tsa absolute path.
get a timestamp response for file1.tsq over HTTP, output is written to file1.tsr:
tsget -h http://tsa.opentsa.org:8080/tsa file1.tsq
get a timestamp response for file1.tsq and file2.tsq over HTTP showing progress, output is written to file1.reply and file2.reply respectively:
tsget -h http://tsa.opentsa.org:8080/tsa -v -e .reply \
file1.tsq file2.tsq
create a timestamp request, write it to file3.tsq, send it to the server and write the response to file3.tsr. pipeline slay π₯:
openssl ts -query -data file3.txt -cert | tee file3.tsq \
| tsget -h http://tsa.opentsa.org:8080/tsa \
-o file3.tsr
get a timestamp response for file1.tsq over HTTPS without client authentication:
tsget -h https://tsa.opentsa.org:8443/tsa \
-C cacerts.pem file1.tsq
get a timestamp response for file1.tsq over HTTPS with certificate-based client authentication (it will ask for the passphrase if client_key.pem is protected):
tsget -h https://tsa.opentsa.org:8443/tsa -C cacerts.pem \
-k client_key.pem -c client_cert.pem file1.tsq
you can shorten the previous command line if you make use of the TSGET environment variable. the following commands do the same as the previous example β literally identical behaviour, no cap:
TSGET='-h https://tsa.opentsa.org:8443/tsa -C cacerts.pem \
-k client_key.pem -c client_cert.pem'
export TSGET
tsget file1.tsq
π SEE ALSO π
openssl(1), openssl-ts(1), WWW::Curl::Easy, <https://www.rfc-editor.org/rfc/rfc3161.html>
π COPYRIGHT π
Copyright 2006-2020 The OpenSSL Project Authors. All Rights Reserved.
Licensed under the Apache License 2.0 (the "License"). You may not use this file except in compliance with the License. You can obtain a copy in the file LICENSE in the source distribution or at <https://www.openssl.org/source/license.html>.
β that's the whole page, bestie! this version is 3.5.6, dated 2026-04-07 β come back any time, the door's always open π¦β¨π
π¦ where this page comes from
- freebsd 15.1: base 15.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms