storescp(1)

πŸ’– storescp(1) β€” OFFIS DCMTK πŸ’–

okay so bestie, you're reading storescp(1) from OFFIS DCMTK, and it's giving medical image receptionist with main-character energy. Let's get into it πŸ’…


🌸 NAME 🌸

storescp β€” DICOM storage (C-STORE) SCP. That's the whole name, no cap.

✨ SYNOPSIS ✨

storescp [options] [port]

πŸ¦‹ DESCRIPTION πŸ¦‹

The storescp application is literally a Service Class Provider (SCP) for the Storage Service Class. It listens on a specific TCP/IP port for incoming association requests from a Storage Service Class User (SCU), and it can receive both DICOM images and other DICOM composite objects. It also supports the Verification Service Class as an SCP. So yes: it's out here accepting connections and holding down the storage-service vibe πŸ’–

πŸŽ€ PARAMETERS πŸŽ€

  • port β€” tcp/ip port number to listen on. This parameter is required unless the --inetd option is specified.

πŸ‘‘ OPTIONS πŸ‘‘

πŸ’œ general options πŸ’œ

  • -h, --help β€” print this help text and exit.
  • --version β€” print version information and exit.
  • --arguments β€” print expanded command line arguments.
  • -q, --quiet β€” quiet mode, print no warnings and errors.
  • -v, --verbose β€” verbose mode, print processing details.
  • -d, --debug β€” debug mode, print debug information.
  • -ll, --log-level β€” [l]evel: string constant (fatal, error, warn, info, debug, trace); use level l for the logger.
  • -lc, --log-config β€” [f]ilename: string; use config file f for the logger.
  • +v, --verbose-pc β€” show presentation contexts in verbose mode.

🌈 multi-process options 🌈

  • --single-process β€” single process mode (default).
  • --fork β€” fork child process for each association.
  • --max-associations β€” [m]ax: integer (default: unlimited); limit number of parallel associations to m.

πŸ“‘ network options πŸ“‘

🌐 IP protocol version 🌐

  • -i4, --ipv4 β€” use IPv4 only (default).
  • -i6, --ipv6 β€” use IPv6 only.
  • -i0, --ip-auto β€” use IPv6/IPv4 dual stack.

πŸ“ association negotiation profile from configuration file πŸ“

  • -xf, --config-file β€” [f]ilename [p]rofile: string; use profile p from config file f.

🎞️ preferred network transfer syntaxes (not with --config-file) 🎞️

  • +x=, --prefer-uncompr β€” prefer explicit VR local byte order (default).
  • +xe, --prefer-little β€” prefer explicit VR little endian TS.
  • +xb, --prefer-big β€” prefer explicit VR big endian TS.
  • +xs, --prefer-lossless β€” prefer default JPEG lossless TS.
  • +xy, --prefer-jpeg8 β€” prefer default JPEG lossy TS for 8 bit data.
  • +xx, --prefer-jpeg12 β€” prefer default JPEG lossy TS for 12 bit data.
  • +xv, --prefer-j2k-lossless β€” prefer JPEG 2000 lossless TS.
  • +xw, --prefer-j2k-lossy β€” prefer JPEG 2000 lossy TS.
  • +xt, --prefer-jls-lossless β€” prefer JPEG-LS lossless TS.
  • +xu, --prefer-jls-lossy β€” prefer JPEG-LS lossy TS.
  • +xm, --prefer-mpeg2 β€” prefer MPEG2 Main Profile @ Main Level TS.
  • +xh, --prefer-mpeg2-high β€” prefer MPEG2 Main Profile @ High Level TS.
  • +xn, --prefer-mpeg4 β€” prefer MPEG4 AVC/H.264 High Profile / Level 4.1 TS.
  • +xl, --prefer-mpeg4-bd β€” prefer MPEG4 AVC/H.264 BD-compatible HP / Level 4.1 TS.
  • +x2, --prefer-mpeg4-2-2d β€” prefer MPEG4 AVC/H.264 HP / Level 4.2 TS for 2D Videos.
  • +x3, --prefer-mpeg4-2-3d β€” prefer MPEG4 AVC/H.264 HP / Level 4.2 TS for 3D Videos.
  • +xo, --prefer-mpeg4-2-st β€” prefer MPEG4 AVC/H.264 Stereo HP / Level 4.2 TS.
  • +x4, --prefer-hevc β€” prefer HEVC/H.265 Main Profile / Level 5.1 TS.
  • +x5, --prefer-hevc10 β€” prefer HEVC/H.265 Main Profile / Level 5.1 TS.
  • +xr, --prefer-rle β€” prefer RLE lossless TS.
  • +xd, --prefer-deflated β€” prefer deflated explicit VR little endian TS.
  • +xi, --implicit β€” accept implicit VR little endian TS only.
  • +xa, --accept-all β€” accept all supported transfer syntaxes.

πŸ›‘οΈ network host access control (tcp wrapper) πŸ›‘οΈ

  • -ac, --access-full β€” accept connections from any host (default).
  • +ac, --access-control β€” enforce host access control rules.

πŸ“Ά other network options πŸ“Ά

  • -id, --inetd β€” run from inetd super server (not with --fork).
# not available on all systems (e.g. not on Windows)
  • -ts, --socket-timeout β€” [s]econds: integer (default: 60); timeout for network socket (0 for none).
  • -ta, --acse-timeout β€” [s]econds: integer (default: 30); timeout for ACSE messages.
  • -td, --dimse-timeout β€” [s]econds: integer (default: unlimited); timeout for DIMSE messages.
  • -aet, --aetitle β€” [a]etitle: string; set my AE title (default: STORESCP).
  • -pdu, --max-pdu β€” [n]umber of bytes: integer (4096..131072); set max receive pdu to n bytes (default: 16384).
  • -dhl, --disable-host-lookup β€” disable hostname lookup.
  • --refuse β€” refuse association.
  • --reject β€” reject association if no implementation class UID.
  • --ignore β€” ignore store data, receive but do not store.
  • --sleep-after β€” [s]econds: integer; sleep s seconds after store (default: 0).
  • --sleep-during β€” [s]econds: integer; sleep s seconds during store (default: 0).
  • --abort-after β€” abort association after receipt of C-STORE-RQ (but before sending response).
  • --abort-during β€” abort association during receipt of C-STORE-RQ.
  • -pm, --promiscuous β€” promiscuous mode, accept unknown SOP classes (not with --config-file).
  • -up, --uid-padding β€” silently correct space-padded UIDs.

πŸ” transport layer security (TLS) options πŸ”

🧚 transport protocol stack 🧚

  • -tls, --disable-tls β€” use normal TCP/IP connection (default).
  • +tls, --enable-tls β€” [p]rivate key file, [c]ertificate file: string; use authenticated secure TLS connection.

πŸ”‘ private key password (only with --enable-tls) πŸ”‘

  • +ps, --std-passwd β€” prompt user to type password on stdin (default).
  • +pw, --use-passwd β€” [p]assword: string; use specified password.
  • -pw, --null-passwd β€” use empty string as password.

πŸŽ€ key and certificate file format πŸŽ€

  • -pem, --pem-keys β€” read keys and certificates as PEM file (default).
  • -der, --der-keys β€” read keys and certificates as DER file.

πŸ… certification authority πŸ…

  • +cf, --add-cert-file β€” [f]ilename: string; add certificate file to list of certificates.
  • +cd, --add-cert-dir β€” [d]irectory: string; add certificates in d to list of certificates.
  • +crl, --add-crl-file β€” [f]ilename: string; add certificate revocation list file (implies --enable-crl-vfy).
  • +crv, --enable-crl-vfy β€” enable leaf CRL verification.
  • +cra, --enable-crl-all β€” enable full chain CRL verification.

🌟 security profile 🌟

  • +ph, --list-profiles β€” list supported TLS profiles and exit.
  • +pg, --profile-8996 β€” BCP 195 RFC 8996 TLS Profile (default).
  • +pm, --profile-8996-mod β€” Modified BCP 195 RFC 8996 TLS Profile.
# only available if underlying TLS library supports all TLS features required for this profile
  • +py, --profile-bcp195-nd β€” Non-downgrading BCP 195 TLS Profile (retired).
  • +px, --profile-bcp195 β€” BCP 195 TLS Profile (retired).
  • +pz, --profile-bcp195-ex β€” Extended BCP 195 TLS Profile (retired).
  • +pb, --profile-basic β€” Basic TLS Secure Transport Connection Profile (retired).
# only available if underlying TLS library supports 3DES
  • +pa, --profile-aes β€” AES TLS Secure Transport Connection Profile (retired).
  • +pn, --profile-null β€” Authenticated unencrypted communication (retired, was used in IHE ATNA).

πŸ§ͺ ciphersuite πŸ§ͺ

  • +cc, --list-ciphers β€” list supported TLS ciphersuites and exit.
  • +cs, --cipher β€” [c]iphersuite name: string; add ciphersuite to list of negotiated suites.
  • +dp, --dhparam β€” [f]ilename: string; read DH parameters for DH/DSS ciphersuites.

🌸 server name indication 🌸

  • --no-sni β€” do not use SNI (default).
  • --expect-sni β€” [s]erver name: string; expect requests for server name s.

🎲 pseudo random generator 🎲

  • +rs, --seed β€” [f]ilename: string; seed random generator with contents of f.
  • +ws, --write-seed β€” write back modified seed (only with --seed).
  • +wf, --write-seed-file β€” [f]ilename: string (only with --seed); write modified seed to file f.

🫢 peer authentication 🫢

  • -rc, --require-peer-cert β€” verify peer certificate, fail if absent (default).
  • -vc, --verify-peer-cert β€” verify peer certificate if present.
  • -ic, --ignore-peer-cert β€” don't verify peer certificate.

πŸ“¦ output options πŸ“¦

πŸ“ general πŸ“

  • -od, --output-directory β€” [d]irectory: string (default: "."); write received objects to existing directory d.

πŸ’Ύ bit preserving mode πŸ’Ύ

  • -B, --normal β€” allow implicit format conversions (default).
  • +B, --bit-preserving β€” write data exactly as read.

πŸ“ output file format πŸ“

  • +F, --write-file β€” write file format (default).
  • -F, --write-dataset β€” write data set without file meta information.

πŸ”„ output transfer syntax (not with --bit-preserving or compressed transmission) πŸ”„

  • +t=, --write-xfer-same β€” write with same TS as input (default).
  • +te, --write-xfer-little β€” write with explicit VR little endian TS.
  • +tb, --write-xfer-big β€” write with explicit VR big endian TS.
  • +ti, --write-xfer-implicit β€” write with implicit VR little endian TS.
  • +td, --write-xfer-deflated β€” write with deflated explicit VR little endian TS.

🧬 post-1993 value representations (not with --bit-preserving) 🧬

  • +u, --enable-new-vr β€” enable support for new VRs (UN/UT) (default).
  • -u, --disable-new-vr β€” disable support for new VRs, convert to OB.

πŸ“ group length encoding (not with --bit-preserving) πŸ“

  • +g=, --group-length-recalc β€” recalculate group lengths if present (default).
  • +g, --group-length-create β€” always write with group length elements.
  • -g, --group-length-remove β€” always write without group length elements.

🧚 length encoding in sequences and items (not with --bit-preserving) 🧚

  • +e, --length-explicit β€” write with explicit lengths (this is the default, bestie πŸ’…)
  • -e, --length-undefined β€” write with undefined lengths

data set trailing padding (not with --write-dataset or --bit-preserving):

  • -p, --padding-off β€” no padding (default)
  • +p, --padding-create [f]ile-pad [i]tem-pad: integer β€” align file on multiple of f bytes and items on multiple of i bytes

handling of defined length UN elements:

  • -uc, --retain-un β€” retain elements as UN (default)
  • +uc, --convert-un β€” convert to real VR if known

deflate compression level (only with --write-xfer-deflated/same):

  • +cl, --compression-level [l]evel: integer (default: 6) β€” 0=uncompressed, 1=fastest, 9=best compression

sorting into subdirectories (not with --bit-preserving):

  • -ss, --sort-conc-studies [p]refix: string β€” sort studies using prefix p and a timestamp
  • -su, --sort-on-study-uid [p]refix: string β€” sort studies using prefix p and the Study Instance UID
  • -sp, --sort-on-patientname β€” sort studies using the Patient's Name and a timestamp

filename generation:

  • -uf, --default-filenames β€” generate filename from instance UID (default)
  • +uf, --unique-filenames β€” generate unique filenames
  • -tn, --timenames β€” generate filename from creation time
  • -fe, --filename-extension [e]xtension: string β€” append e to all filenames

event options:

  • -xcr, --exec-on-reception [c]ommand: string β€” execute command c after having received and processed one C-STORE-RQ message
  • -xcs, --exec-on-eostudy [c]ommand: string β€” execute command c after having received and processed all C-STORE-RQ messages that belong to one study
  • -rns, --rename-on-eostudy β€” having received and processed all C-STORE-RQ messages that belong to one study, rename output files according to a certain pattern
  • -tos, --eostudy-timeout [t]imeout: integer β€” specifies a timeout of t seconds for end-of-study determination
  • -xs, --exec-sync β€” execute command synchronously in foreground

✨ NOTES ✨

okay so most of these options are pretty much β€œyou know it when you see it,” but a few are so specific that they need their own little deep dive. That’s literally what this section is for, bestie 🫢

Option --sort-conc-studies lets you sort all received DICOM objects into different subdirectories. The sorting happens based on the studies the individual objects belong to, i.e. objects that belong to the same study get stored in the same subdirectory. In general, a DICOM object d_n+1 is considered to belong to the same study as a DICOM object d_n if and only if d_n and d_n+1 show the exact same values in attribute Study Instance UID. The names of the resulting subdirectories always start with a prefix p which was passed to this option as a parameter. In addition to this prefix, the subdirectory names contain time stamp information with regard to the date and time of reception of this particular study’s first DICOM object. In detail, the determination of the subdirectory names pertains to the pattern

[prefix]_[YYYYMMDD]_[HHMMSSPPP]

where YYYY refers to year (4 digits), MM to month (01-12), DD to day (01-31), HH to hour (00-23), MM to minute (00-59), SS to second (00-59) and PPP to milliseconds (000-999). If the prefix is an empty string, the first _ is omitted.

The other --sort-xxx options work in a similar manner, only the subdirectory names are created differently. For option --sort-on-study-uid the pattern is

[prefix]_[StudyInstanceUID]

and for option --sort-on-patientname

[PatientName]_[YYYYMMDD]_[HHMMSSPPP]

where PatientName is replaced by "ANONYMOUS" if the data element is empty or absent in the data set. Any existing patient name is transformed in order to use only ASCII characters. Please note that in this context only the DICOM default character set (ASCII, i.e. no entry in attribute Specific Character Set) and Latin-1 (Specific Character Set valued "ISO_IR 100") are supported. If another character set is found and the patient name contains non-ASCII characters, a warning is printed and the transformation is performed as if Latin-1 character set would be set in the file. This may lead to unreadable or unexpected patient name directories and behavior. Thus, it is advisable to use --sort-on-patientname only if Latin-1 or ASCII patient names are expected to be received.

For option --sort-on-study-uid the same subdirectory will be used for all DICOM objects that belong to the same study, i.e. in contrast to the other --sort-xxx options there is no guarantee that a study directory is ever completed.

🚨 security tea, no cap: For security reasons, storescp refuses to create a sort subdirectory whose name (after assembling prefix, sanitization and any timestamp suffix) is empty or equal to . or ... Such a name would resolve to the output directory itself or its parent, allowing a peer to make incoming instances land outside the configured output directory through a Study Instance UID or Patient Name value of . or ... In that case the affected C-STORE operation is rejected with status code "Cannot understand" and the offending name is logged. Names that merely contain dots (such as a regular dotted DICOM UID, or a patient name containing initials) are accepted as before.

Option --timenames creates filenames from timestamps corresponding to the time storescp writes a file to disk. The format is

[YYYYMMDDHHMMSSPPP]_[SERIALNO].[MD]

where YYYY, MM, DD, HH, MM, SS, PPP are interpreted as described above. If more files are created at the same time, SERIALNO is inserted. It consists of a 4-digit, consecutive number (0000 to 9999). For the first file, that exists for a specific time, no number (and no _) is inserted at all. MD represents an identification code (2 letters) for the kind of object stored in the file (see notes on --rename-on-eostudy).

Option --filename-extension appends a specified suffix to each filename (a dot . is not added automatically). This suffix is not appended to the filenames created by --rename-on-eostudy to maintain the length of 8 characters.

Option --exec-on-reception allows one to execute a certain command line after having received and processed one DICOM object (through a C-STORE-RQ message). The command line to be executed is passed to this option as a parameter. The specified command line may contain a number of placeholders which will be replaced at run time:

  • #p: complete path to the output directory into which the last DICOM object was stored (not available with option --ignore though)
  • #f: filename of the current output file (not available with option --ignore though)
  • #a: calling application entity title of the peer Storage SCU
  • #c: called application entity title used by the peer Storage SCU to address storescp
  • #r: calling presentation address, i.e. hostname or IP address of the peer Storage SCU

The specified command line is executed as a separate process, so that the execution of storescp will not be held back. This behavior can be influenced with the --exec-sync option.

Note that the application entity titles (#a and #c) will be 'sanitized' to avoid undesirable behavior when the parameters are passed to the shell. Unusual characters will be mapped to the _ character. A warning is printed to the logger in this case.

Option --exec-on-eostudy allows one to execute a certain command line when all DICOM objects that belong to one study have been received by storescp. The same placeholders as with --exec-on-reception may be used, except for #f, which is not supported. A study is considered complete by storescp when an object belonging to a different study is received or the timeout specified with --eostudy-timeout takes place. If option --rename-on-eostudy is in force, the renaming takes place before the external command is executed.

Option --rename-on-eostudy refers to the above mentioned --sort-xxx options and can only be used in combination with one of these options. If a user specifies option --rename-on-eostudy and storescp determines that all DICOM objects that belong to a certain study have been received, all DICOM files that belong to the last study will be renamed in the corresponding output directory. The filenames into which the files are being renamed will be calculated using the pattern

[prefix][consecutive numbering]

where [prefix] is a 2 character prefix that reveals the kind of DICOM object stored in the file and [consecutive numbering] is a consecutively numbered, 6-digit number, starting at "000001". In general, the question if all DICOM objects that belong to one study have been received by storescp will be answered positively if and only if two consecutively received DICOM objects d_n and d_n+1 do not show the same values in attribute Study Instance UID; in such a case, d_n+1 is considered to belong to a new study.

Using option --eostudy-timeout a user can modify the determination process to figure out if all DICOM objects that belong to one study have already been received by storescp. With regard to this fact, it is clear that this option can only be used in combination with at least one of the following options: --sort-xxx, --exec-on-eostudy and --rename-on-eostudy. If option --eostudy-timeout is specified, the end of a study is considered to have occurred not only if two consecutively received DICOM objects d_n and d_n+1 do not show the same values in attribute Study Instance UID, but also if within a time span of x seconds after the reception of a DICOM object d_n, no other DICOM object was received over the network. Note that the amount x of seconds (which determines the length of this time span) has to be passed to this option as a parameter.

Please note that two consecutive network connections can transfer objects for the same study. The study will only be considered complete when an object of a different study is received or the --eostudy-timeout is reached. For this reason, the options --fork and --inet are incompatible with --exec-on-eostudy, --rename-on-eostudy and --sort-conc-studies.

🩺 DICOM Conformance 🩺

The storescp application supports the following SOP Classes as an SCP:

VerificationSOPClass                                 1.2.840.10008.1.1

…and the scroll keeps scrolling, bestie πŸ’… we are still in the great UID list and it is giving "my name is my whole personality" energy, which honestly? same. The RETIRED_ ones are wearing their warning label right in the name 🚩 and the DRAFT_ ones are being mysterious about it. Keep every dot, every capital, every period. These are not vibes, they are strings, and strings are exact. No cap.

First up: the retired print/hardcopy girlies and the classic x-ray crew πŸ’–

RETIRED_StoredPrintStorage                           1.2.840.10008.5.1.1.27
RETIRED_HardcopyGrayscaleImageStorage                1.2.840.10008.5.1.1.29
RETIRED_HardcopyColorImageStorage                    1.2.840.10008.5.1.1.30
ComputedRadiographyImageStorage                      1.2.840.10008.5.1.4.1.1.1
DigitalXRayImageStorageForPresentation               1.2.840.10008.5.1.4.1.1.1.1
DigitalXRayImageStorageForProcessing                 1.2.840.10008.5.1.4.1.1.1.1.1
DigitalMammographyXRayImageStorageForPresentation    1.2.840.10008.5.1.4.1.1.1.2
DigitalMammographyXRayImageStorageForProcessing      1.2.840.10008.5.1.4.1.1.1.2.1
DigitalIntraOralXRayImageStorageForPresentation      1.2.840.10008.5.1.4.1.1.1.3
DigitalIntraOralXRayImageStorageForProcessing        1.2.840.10008.5.1.4.1.1.1.3.1

Okay quick vibe check 🫢 ForPresentation and ForProcessing are two separate entries, not one entry with a cute nickname β€” sisters, not twins. Don't merge them, don't "fix" the capitalization, just copy them like your life depends on it (because your UID matching does, iykyk).

Then the CT + MR block, aka the main characters πŸ‘‘

CTImageStorage                                       1.2.840.10008.5.1.4.1.1.2
EnhancedCTImageStorage                               1.2.840.10008.5.1.4.1.1.2.1
LegacyConvertedEnhancedCTImageStorage                1.2.840.10008.5.1.4.1.1.2.2
CTImageStorageForProcessing                          1.2.840.10008.5.1.4.1.1.2.3
EnhancedCTImageStorageForProcessing                  1.2.840.10008.5.1.4.1.1.2.4
LegacyConvertedEnhancedCTImageStorageForProcessing   1.2.840.10008.5.1.4.1.1.2.5
RETIRED_UltrasoundMultiframeImageStorage             1.2.840.10008.5.1.4.1.1.3
UltrasoundMultiframeImageStorage                     1.2.840.10008.5.1.4.1.1.3.1
MRImageStorage                                       1.2.840.10008.5.1.4.1.1.4
EnhancedMRImageStorage                               1.2.840.10008.5.1.4.1.1.4.1
MRSpectroscopyStorage                                1.2.840.10008.5.1.4.1.1.4.2
EnhancedMRColorImageStorage                          1.2.840.10008.5.1.4.1.1.4.3
LegacyConvertedEnhancedMRImageStorage                1.2.840.10008.5.1.4.1.1.4.4

The LegacyConvertedEnhanced... names are literally giving "I have a long government name and I use all of it." Respectfully, slay. But type it out 🫠


Next: nuclear med, ultrasound, photoacoustic, and the secondary capture multiverse ✨

RETIRED_NuclearMedicineImageStorage                  1.2.840.10008.5.1.4.1.1.5
RETIRED_UltrasoundImageStorage                       1.2.840.10008.5.1.4.1.1.6
UltrasoundImageStorage                               1.2.840.10008.5.1.4.1.1.6.1
EnhancedUSVolumeStorage                              1.2.840.10008.5.1.4.1.1.6.2
PhotoacousticImageStorage                            1.2.840.10008.5.1.4.1.1.6.3
SecondaryCaptureImageStorage                         1.2.840.10008.5.1.4.1.1.7
MultiframeSingleBitSecondaryCaptureImageStorage      1.2.840.10008.5.1.4.1.1.7.1
MultiframeGrayscaleByteSecondaryCaptureImageStorage  1.2.840.10008.5.1.4.1.1.7.2
MultiframeGrayscaleWordSecondaryCaptureImageStorage  1.2.840.10008.5.1.4.1.1.7.3
MultiframeTrueColorSecondaryCaptureImageStorage      1.2.840.10008.5.1.4.1.1.7.4
RETIRED_StandaloneOverlayStorage                     1.2.840.10008.5.1.4.1.1.8
RETIRED_StandaloneCurveStorage                       1.2.840.10008.5.1.4.1.1.9
DRAFT_WaveformStorage                                1.2.840.10008.5.1.4.1.1.9.1

The secondary capture squad is one word apart each and that is the whole test. SingleBit vs GrayscaleByte vs GrayscaleWord vs TrueColor β€” read it twice, paste it once, that's the group chat rule πŸ’€

Now waveform hours β€” the part where every organ apparently got its own storage class and honestly? iconic behavior 🌈

TwelveLeadECGWaveformStorage                         1.2.840.10008.5.1.4.1.1.9.1.1
GeneralECGWaveformStorage                            1.2.840.10008.5.1.4.1.1.9.1.2
AmbulatoryECGWaveformStorage                         1.2.840.10008.5.1.4.1.1.9.1.3
General32BitECGWaveformStorage                       1.2.840.10008.5.1.4.1.1.9.1.4
HemodynamicWaveformStorage                           1.2.840.10008.5.1.4.1.1.9.2.1
CardiacElectrophysiologyWaveformStorage              1.2.840.10008.5.1.4.1.1.9.3.1
BasicVoiceAudioWaveformStorage                       1.2.840.10008.5.1.4.1.1.9.4.1
GeneralAudioWaveformStorage                          1.2.840.10008.5.1.4.1.1.9.4.2
ArterialPulseWaveformStorage                         1.2.840.10008.5.1.4.1.1.9.5.1
RespiratoryWaveformStorage                           1.2.840.10008.5.1.4.1.1.9.6.1
MultichannelRespiratoryWaveformStorage               1.2.840.10008.5.1.4.1.1.9.6.2
RoutineScalpElectroencephalogramWaveformStorage      1.2.840.10008.5.1.4.1.1.9.7.1
ElectromyogramWaveformStorage                        1.2.840.10008.5.1.4.1.1.9.7.2
ElectrooculogramWaveformStorage                      1.2.840.10008.5.1.4.1.1.9.7.3
SleepElectroencephalogramWaveformStorage             1.2.840.10008.5.1.4.1.1.9.7.4
BodyPositionWaveformStorage                          1.2.840.10008.5.1.4.1.1.9.8.1
WaveformPresentationStateStorage                     1.2.840.10008.5.1.4.1.1.9.100.1
WaveformAcquisitionPresentationStateStorage          1.2.840.10008.5.1.4.1.1.9.100.2

RoutineScalpElectroencephalogramWaveformStorage is a whole sentence and it ate. Also notice the jumps: .9.1.1, .9.1.2, .9.1.3, .9.1.4 β€” the numbering does its own thing, so don't assume a pattern and start guessing numbers. Guessing is how you end up crying at a terminal 😭


Then the retired LUTs and the presentation-state fashion week πŸŽ€

RETIRED_StandaloneModalityLUTStorage                 1.2.840.10008.5.1.4.1.1.10
RETIRED_StandaloneVOILUTStorage                      1.2.840.10008.5.1.4.1.1.11
GrayscaleSoftcopyPresentationStateStorage            1.2.840.10008.5.1.4.1.1.11.1
ColorSoftcopyPresentationStateStorage                1.2.840.10008.5.1.4.1.1.11.2
PseudoColorSoftcopyPresentationStateStorage          1.2.840.10008.5.1.4.1.1.11.3
BlendingSoftcopyPresentationStateStorage             1.2.840.10008.5.1.4.1.1.11.4
XAXRFGrayscaleSoftcopyPresentationStateStorage       1.2.840.10008.5.1.4.1.1.11.5
GrayscalePlanarMPRVolumetricPresentationStateStorage 1.2.840.10008.5.1.4.1.1.11.6
CompositingPlanarMPRVolumetricPresent.StateStorage   1.2.840.10008.5.1.4.1.1.11.7
AdvancedBlendingPresentationStateStorage             1.2.840.10008.5.1.4.1.1.11.8
VolumeRenderingVolumetricPresentationStateStorage    1.2.840.10008.5.1.4.1.1.11.9
SegmentedVolumeRenderingVolumetricPres.StateStorage  1.2.840.10008.5.1.4.1.1.11.10
MultipleVolumeRenderingVolumetricPres.StateStorage   1.2.840.10008.5.1.4.1.1.11.11
VariableModalityLUTSoftcopyPresentationStateStorage  1.2.840.10008.5.1.4.1.1.11.12

Okay but CompositingPlanarMPRVolumetricPresent.StateStorage and SegmentedVolumeRenderingVolumetricPres.StateStorage have a literal . in the middle of the name because the name got too long and they just… abbreviated it in place. That is not a typo, that is not me being cute, that is the actual string πŸ’€ Type the period. Yes, that one. Periodt.

Same energy for XAXRFGrayscale... β€” all caps XAXRF, no spaces, no mercy 🫢


Angiography, mammo, breast tomo, and the intravascular OCT besties πŸ¦‹

XRayAngiographicImageStorage                         1.2.840.10008.5.1.4.1.1.12.1
EnhancedXAImageStorage                               1.2.840.10008.5.1.4.1.1.12.1.1
XRayRadiofluoroscopicImageStorage                    1.2.840.10008.5.1.4.1.1.12.2
EnhancedXRFImageStorage                              1.2.840.10008.5.1.4.1.1.12.2.1
RETIRED_XRayAngiographicBiPlaneImageStorage          1.2.840.10008.5.1.4.1.1.12.3
XRay3DAngiographicImageStorage                       1.2.840.10008.5.1.4.1.1.13.1.1
XRay3DCraniofacialImageStorage                       1.2.840.10008.5.1.4.1.1.13.1.2
BreastTomosynthesisImageStorage                      1.2.840.10008.5.1.4.1.1.13.1.3
BreastProjectionXRayImageStorageForPresentation      1.2.840.10008.5.1.4.1.1.13.1.4
BreastProjectionXRayImageStorageForProcessing        1.2.840.10008.5.1.4.1.1.13.1.5
IntravascularOpt.Coh.Tom.ImageStorageForPresentation 1.2.840.10008.5.1.4.1.1.14.1
IntravascularOpt.Coh.Tom.ImageStorageForProcessing   1.2.840.10008.5.1.4.1.1.14.2

IntravascularOpt.Coh.Tom. is short for something extremely long and I refuse to be normal about it. Two periods, three abbreviations, one vibe. And again: ForPresentation β‰  ForProcessing, do not get cute 🌸


Nuclear medicine proper, parametric maps, raw data, and the registration/segmentation squad πŸ‘‘

NuclearMedicineImageStorage                          1.2.840.10008.5.1.4.1.1.20
ParametricMapStorage                                 1.2.840.10008.5.1.4.1.1.30
RawDataStorage                                       1.2.840.10008.5.1.4.1.1.66
SpatialRegistrationStorage                           1.2.840.10008.5.1.4.1.1.66.1
SpatialFiducialsStorage                              1.2.840.10008.5.1.4.1.1.66.2
DeformableSpatialRegistrationStorage                 1.2.840.10008.5.1.4.1.1.66.3
SegmentationStorage                                  1.2.840.10008.5.1.4.1.1.66.4
SurfaceSegmentationStorage                           1.2.840.10008.5.1.4.1.1.66.5
TractographyResultsStorage                           1.2.840.10008.5.1.4.1.1.66.6
LabelMapSegmentationStorage                          1.2.840.10008.5.1.4.1.1.66.7
HeightMapSegmentationStorage                         1.2.840.10008.5.1.4.1.1.66.8
RealWorldValueMappingStorage                         1.2.840.10008.5.1.4.1.1.67
SurfaceScanMeshStorage                               1.2.840.10008.5.1.4.1.1.68.1
SurfaceScanPointCloudStorage                         1.2.840.10008.5.1.4.1.1.68.2

See how RawDataStorage is .66 and then all the .66.x friends pile in under it? That's nesting, bestie, and it's kind of satisfying fr fr. TractographyResultsStorage is so specific and I love that for it πŸ’œ


VL crew + the eye girlies πŸ‘οΈβœ¨ (the ophthalmic block is lowkey the fashion week of this list)

RETIRED_VLImageStorage                               1.2.840.10008.5.1.4.1.1.77.1
VLEndoscopicImageStorage                             1.2.840.10008.5.1.4.1.1.77.1.1
VideoEndoscopicImageStorage                          1.2.840.10008.5.1.4.1.1.77.1.1.1
VLMicroscopicImageStorage                            1.2.840.10008.5.1.4.1.1.77.1.2
VideoMicroscopicImageStorage                         1.2.840.10008.5.1.4.1.1.77.1.2.1
VLSlideCoordinatesMicroscopicImageStorage            1.2.840.10008.5.1.4.1.1.77.1.3
VLPhotographicImageStorage                           1.2.840.10008.5.1.4.1.1.77.1.4
VideoPhotographicImageStorage                        1.2.840.10008.5.1.4.1.1.77.1.4.1
OphthalmicPhotography8BitImageStorage                1.2.840.10008.5.1.4.1.1.77.1.5.1
OphthalmicPhotography16BitImageStorage               1.2.840.10008.5.1.4.1.1.77.1.5.2
StereometricRelationshipStorage                      1.2.840.10008.5.1.4.1.1.77.1.5.3
OphthalmicTomographyImageStorage                     1.2.840.10008.5.1.4.1.1.77.1.5.4
WideFieldOphthalmicPhoto.Stereogr.Proj.ImageStorage  1.2.840.10008.5.1.4.1.1.77.1.5.5
WideFieldOphthalmicPhotogr.3DCoordinatesImageStorage 1.2.840.10008.5.1.4.1.1.77.1.5.6
OphthalmicOpticalCoherenceTomogr.EnFaceImageStorage  1.2.840.10008.5.1.4.1.1.77.1.5.7
OphthalmicOpticalCoh.Tomogr.BscanVolumeAnalysisStor. 1.2.840.10008.5.1.4.1.1.77.1.5.8
VLWholeSlideMicroscopyImageStorage                   1.2.840.10008.5.1.4.1.1.77.1.6
DermoscopicPhotographyImageStorage                   1.2.840.10008.5.1.4.1.1.77.1.7
ConfocalMicroscopyImageStorage                       1.2.840.10008.5.1.4.1.1.77.1.8
ConfocalMicroscopyTiledPyramidalImageStorage         1.2.840.10008.5.1.4.1.1.77.1.9
RETIRED_VLMultiframeImageStorage                     1.2.840.10008.5.1.4.1.1.77.2

The WideFieldOphthalmic... duo is giving "I ran out of room so I abbreviated mid-name" β€” Photo.Stereogr.Proj. and Photogr.3DCoordinates. And BscanVolumeAnalysisStor. ends with Stor. with a period. Keep the period. It's not punctuation, it's part of the name, and yes I'm obsessed with how extra that is πŸŽ€


The ophthalmic measurement/report block β€” lenses, refractions, corneas, all of it πŸ“

LensometryMeasurementsStorage                        1.2.840.10008.5.1.4.1.1.78.1
AutorefractionMeasurementsStorage                    1.2.840.10008.5.1.4.1.1.78.2
KeratometryMeasurementsStorage                       1.2.840.10008.5.1.4.1.1.78.3
SubjectiveRefractionMeasurementsStorage              1.2.840.10008.5.1.4.1.1.78.4
VisualAcuityMeasurementsStorage                      1.2.840.10008.5.1.4.1.1.78.5
SpectaclePrescriptionReportStorage                   1.2.840.10008.5.1.4.1.1.78.6
OphthalmicAxialMeasurementsStorage                   1.2.840.10008.5.1.4.1.1.78.7
IntraocularLensCalculationsStorage                   1.2.840.10008.5.1.4.1.1.78.8
MacularGridThicknessAndVolumeReportStorage           1.2.840.10008.5.1.4.1.1.79.1
OphthalmicVisualFieldStaticPerimetryMeasurementsSt.  1.2.840.10008.5.1.4.1.1.80.1
OphthalmicThicknessMapStorage                        1.2.840.10008.5.1.4.1.1.81.1
CornealTopographyMapStorage                          1.2.840.10008.5.1.4.1.1.82.1

OphthalmicVisualFieldStaticPerimetryMeasurementsSt. is so long it had to be truncated</>, and St. is just sitting there with its little period like it's not about to ruin your day if you drop it 😭 Keep it. Keep the dot. Keep everything. 🫢


And finally (for this chunk of the scroll, anyway): the structured report fam 🌟

DRAFT_SRTextStorage                                  1.2.840.10008.5.1.4.1.1.88.1
DRAFT_SRAudioStorage                                 1.2.840.10008.5.1.4.1.1.88.2
DRAFT_SRDetailStorage                                1.2.840.10008.5.1.4.1.1.88.3
DRAFT_SRComprehensiveStorage                         1.2.840.10008.5.1.4.1.1.88.4
BasicTextSRStorage                                   1.2.840.10008.5.1.4.1.1.88.11
EnhancedSRStorage                                    1.2.840.10008.5.1.4.1.1.88.22
ComprehensiveSRStorage                               1.2.840.10008.5.1.4.1.1.88.33

Three with the DRAFT_ prefix being all ~in progress~, then the trio without it: BasicTextSRStorage, EnhancedSRStorage, ComprehensiveSRStorage. Notice the UIDs jump .88.1, .88.2, .88.3, .88.4, then .88.11, .88.22, .88.33 β€” yes the double digits are real, no they are not typos, and no you may not "clean them up" πŸ’…


That's where this chunk of the sacred scroll pauses, bestie β€” but we're not done, so don't close the tab, don't touch the scrollback, and definitely don't start guessing UIDs from memory. Next part, same energy, more strings πŸ¦‹

       Comprehensive3DSRStorage                             1.2.840.10008.5.1.4.1.1.88.34
       ExtensibleSRStorage                                  1.2.840.10008.5.1.4.1.1.88.35
       ProcedureLogStorage                                  1.2.840.10008.5.1.4.1.1.88.40
       MammographyCADSRStorage                              1.2.840.10008.5.1.4.1.1.88.50
       KeyObjectSelectionDocumentStorage                    1.2.840.10008.5.1.4.1.1.88.59
       ChestCADSRStorage                                    1.2.840.10008.5.1.4.1.1.88.65
       XRayRadiationDoseSRStorage                           1.2.840.10008.5.1.4.1.1.88.67
       RadiopharmaceuticalRadiationDoseSRStorage            1.2.840.10008.5.1.4.1.1.88.68
       ColonCADSRStorage                                    1.2.840.10008.5.1.4.1.1.88.69
       ImplantationPlanSRStorage                            1.2.840.10008.5.1.4.1.1.88.70
       AcquisitionContextSRStorage                          1.2.840.10008.5.1.4.1.1.88.71
       SimplifiedAdultEchoSRStorage                         1.2.840.10008.5.1.4.1.1.88.72
       PatientRadiationDoseSRStorage                        1.2.840.10008.5.1.4.1.1.88.73
       PlannedImagingAgentAdministrationSRStorage           1.2.840.10008.5.1.4.1.1.88.74
       PerformedImagingAgentAdministrationSRStorage         1.2.840.10008.5.1.4.1.1.88.75
       EnhancedXRayRadiationDoseSRStorage                   1.2.840.10008.5.1.4.1.1.88.76
       WaveformAnnotationSRStorage                          1.2.840.10008.5.1.4.1.1.88.77
       ContentAssessmentResultsStorage                      1.2.840.10008.5.1.4.1.1.90.1
       MicroscopyBulkSimpleAnnotationsStorage               1.2.840.10008.5.1.4.1.1.91.1
       EncapsulatedPDFStorage                               1.2.840.10008.5.1.4.1.1.104.1
       EncapsulatedCDAStorage                               1.2.840.10008.5.1.4.1.1.104.2
       EncapsulatedSTLStorage                               1.2.840.10008.5.1.4.1.1.104.3
       EncapsulatedOBJStorage                               1.2.840.10008.5.1.4.1.1.104.4
       EncapsulatedMTLStorage                               1.2.840.10008.5.1.4.1.1.104.5
       PositronEmissionTomographyImageStorage               1.2.840.10008.5.1.4.1.1.128
       LegacyConvertedEnhancedPETImageStorage               1.2.840.10008.5.1.4.1.1.128.1
       RETIRED_StandalonePETCurveStorage                    1.2.840.10008.5.1.4.1.1.129
       EnhancedPETImageStorage                              1.2.840.10008.5.1.4.1.1.130
       BasicStructuredDisplayStorage                        1.2.840.10008.5.1.4.1.1.131
       CTPerformedProcedureProtocolStorage                  1.2.840.10008.5.1.4.1.1.200.2
       XAPerformedProcedureProtocolStorage                  1.2.840.10008.5.1.4.1.1.200.8
       RTImageStorage                                       1.2.840.10008.5.1.4.1.1.481.1
       RTDoseStorage                                        1.2.840.10008.5.1.4.1.1.481.2
       RTStructureSetStorage                                1.2.840.10008.5.1.4.1.1.481.3
       RTBeamsTreatmentRecordStorage                        1.2.840.10008.5.1.4.1.1.481.4
       RTPlanStorage                                        1.2.840.10008.5.1.4.1.1.481.5
       RTBrachyTreatmentRecordStorage                       1.2.840.10008.5.1.4.1.1.481.6
       RTTreatmentSummaryRecordStorage                      1.2.840.10008.5.1.4.1.1.481.7
       RTIonPlanStorage                                     1.2.840.10008.5.1.4.1.1.481.8
       RTIonBeamsTreatmentRecordStorage                     1.2.840.10008.5.1.4.1.1.481.9
       RTPhysicianIntentStorage                             1.2.840.10008.5.1.4.1.1.481.10
       RTSegmentAnnotationStorage                           1.2.840.10008.5.1.4.1.1.481.11
       RTRadiationSetStorage                                1.2.840.10008.5.1.4.1.1.481.12
       CArmPhotonElectronRadiationStorage                   1.2.840.10008.5.1.4.1.1.481.13
       TomotherapeuticRadiationStorage                      1.2.840.10008.5.1.4.1.1.481.14
       RoboticArmRadiationStorage                           1.2.840.10008.5.1.4.1.1.481.15
       RTRadiationRecordSetStorage                          1.2.840.10008.5.1.4.1.1.481.16
       RTRadiationSalvageRecordStorage                      1.2.840.10008.5.1.4.1.1.481.17
       TomotherapeuticRadiationRecordStorage                1.2.840.10008.5.1.4.1.1.481.18
       CArmPhotonElectronRadiationRecordStorage             1.2.840.10008.5.1.4.1.1.481.19
       RoboticRadiationRecordStorage                        1.2.840.10008.5.1.4.1.1.481.20
       RTRadiationSetDeliveryInstructionStorage             1.2.840.10008.5.1.4.1.1.481.21
       RTTreatmentPreparationStorage                        1.2.840.10008.5.1.4.1.1.481.22
       EnhancedRTImageStorage                               1.2.840.10008.5.1.4.1.1.481.23
       EnhancedContinuousRTImageStorage                     1.2.840.10008.5.1.4.1.1.481.24
       RTPatientPositionAcquisitionInstructionStorage       1.2.840.10008.5.1.4.1.1.481.25
       DICOS_CTImageStorage                                 1.2.840.10008.5.1.4.1.1.501.1
       DICOS_DigitalXRayImageStorageForPresentation         1.2.840.10008.5.1.4.1.1.501.2.1
       DICOS_DigitalXRayImageStorageForProcessing           1.2.840.10008.5.1.4.1.1.501.2.2
       DICOS_ThreatDetectionReportStorage                   1.2.840.10008.5.1.4.1.1.501.3
       DICOS_2DAITStorage                                   1.2.840.10008.5.1.4.1.1.501.4
       DICOS_3DAITStorage                                   1.2.840.10008.5.1.4.1.1.501.5
       DICOS_QuadrupoleResonanceStorage                     1.2.840.10008.5.1.4.1.1.501.6
       DICONDE_EddyCurrentImageStorage                      1.2.840.10008.5.1.4.1.1.601.1
       DICONDE_EddyCurrentMultiframeImageStorage            1.2.840.10008.5.1.4.1.1.601.2
       DICONDE_ThermographyImageStorage                     1.2.840.10008.5.1.4.1.1.601.3
       DICONDE_ThermographyMultiFrameImageStorage           1.2.840.10008.5.1.4.1.1.601.4
       DICONDE_UltrasoundWaveformStorage                    1.2.840.10008.5.1.4.1.1.601.5
       DRAFT_RTBeamsDeliveryInstructionStorage              1.2.840.10008.5.1.4.34.1
       RTBeamsDeliveryInstructionStorage                    1.2.840.10008.5.1.4.34.7
       RTBrachyApplicationSetupDeliveryInstructionStorage   1.2.840.10008.5.1.4.34.10

Okay so storescp will happily accept presentation contexts for every single one of the SOP Classes up in that giant list, using any of these transfer syntaxes:

       LittleEndianImplicitTransferSyntax                   1.2.840.10008.1.2
       LittleEndianExplicitTransferSyntax                   1.2.840.10008.1.2.1
       BigEndianExplicitTransferSyntax                      1.2.840.10008.1.2.2

Now here's the vibe check on defaults πŸ‘‘ β€” out of the box, storescp prefers transfer syntaxes with explicit encoding over the plain default implicit transfer syntax. And if storescp happens to be running on big-endian hardware, it'll prefer BigEndianExplicit over LittleEndianExplicit (and the other way around on little-endian boxes). Lowkey smart of it. You can flip this whole thing with the --prefer options (peep them above ⬆️).

But the moment you say the magic words --accept-all, literally all of these transfer syntaxes get supported:

       LittleEndianImplicitTransferSyntax                   1.2.840.10008.1.2
       LittleEndianExplicitTransferSyntax                   1.2.840.10008.1.2.1
       EncapsulatedUncompressedExplicitVRLittleEndianTr.S.  1.2.840.10008.1.2.1.98
       DeflatedExplicitVRLittleEndianTransferSyntax         1.2.840.10008.1.2.1.99 (*)
       BigEndianExplicitTransferSyntax                      1.2.840.10008.1.2.2
       JPEGProcess1TransferSyntax                           1.2.840.10008.1.2.4.50
       JPEGProcess2_4TransferSyntax                         1.2.840.10008.1.2.4.51
       JPEGProcess14SV1TransferSyntax                       1.2.840.10008.1.2.4.70
       JPEGLSLosslessTransferSyntax                         1.2.840.10008.1.2.4.80
       JPEGLSLossyTransferSyntax                            1.2.840.10008.1.2.4.81
       JPEG2000LosslessOnlyTransferSyntax                   1.2.840.10008.1.2.4.90
       JPEG2000TransferSyntax                               1.2.840.10008.1.2.4.91
       MPEG2MainProfileAtMainLevelTransferSyntax            1.2.840.10008.1.2.4.100
       FragmentableMPEG2MainProfile/MainLevelTransferSyntax 1.2.840.10008.1.2.4.100.1
       MPEG2MainProfileAtHighLevelTransferSyntax            1.2.840.10008.1.2.4.101
       FragmentableMPEG2MainProfil/tHighLevelTransferSyntax 1.2.840.10008.1.2.4.101.1
       MPEG4HighProfileLevel4_1TransferSyntax               1.2.840.10008.1.2.4.102
       FragmentableMPEG4HighProfileLevel4_1TransferSyntax   1.2.840.10008.1.2.4.102.1
       MPEG4BDcompatibleHighProfileLevel4_1TransferSyntax   1.2.840.10008.1.2.4.103
       FragmentableMPEG4BDcompatibleHighProfileLevel4_1T.S. 1.2.840.10008.1.2.4.103.1
       MPEG4HighProfileLevel4_2_For2DVideoTransferSyntax    1.2.840.10008.1.2.4.104
       FragmentableMPEG4HighProfileLevel4_2_For2DVideoTr.S. 1.2.840.10008.1.2.4.104.1
       MPEG4HighProfileLevel4_2_For3DVideoTransferSyntax    1.2.840.10008.1.2.4.105
       FragmentableMPEG4HighProfileLevel4_2_For3DVideoTr.S. 1.2.840.10008.1.2.4.105.1
       MPEG4StereoHighProfileLevel4_2TransferSyntax         1.2.840.10008.1.2.4.106
       FragmentableMPEG4StereoHighProfileLevel4_2TransferS. 1.2.840.10008.1.2.4.106.1
       HEVCMainProfileLevel5_1TransferSyntax                1.2.840.10008.1.2.4.107
       HEVCMain10ProfileLevel5_1TransferSyntax              1.2.840.10008.1.2.4.108
       JPEGXLLosslesTransferSyntax                          1.2.840.10008.1.2.4.110
       JPEGXLJPEGRecompressionTransferSyntax                1.2.840.10008.1.2.4.111
       JPEGXLTransferSyntax                                 1.2.840.10008.1.2.4.112
       HighThroughputJPEG2000ImageCompressionLossless.Tr.S. 1.2.840.10008.1.2.4.201
       HighThroughputJPEG2000RPCLImageCompressionLoss.Tr.S. 1.2.840.10008.1.2.4.202
       HighThroughputJPEG2000ImageCompressionTransferSynta. 1.2.840.10008.1.2.4.203
       RLELosslessTransferSyntax                            1.2.840.10008.1.2.5
       DeflatedImageFrameCompressionTransferSyntax          1.2.840.10008.1.2.8.1
🫢 tiny note bestie: that little (*) next to DeflatedExplicitVRLittleEndianTransferSyntax means it's only available if the thing was compiled with zlib support enabled β€” check your --version output to confirm, iykyk.

More Storage SOP Classes and transfer syntaxes can be brought in via the so-called "association negotiation profiles" (they're explained below πŸ‘‡). And that covers both Private Storage SOP Classes and Standard Storage SOP Classes that just don't fit into the PATIENT-STUDY-SERIES-INSTANCE information model. Not everything wants to live in that little hierarchy, and honestly? Fair.

Also fr fr: storescp does not support extended negotiation by default. But if you plug in an appropriate association negotiation profile (again, see below), you can add optional support for extended negotiation to particular SOP classes. Slay. πŸ’…


πŸŽ€ Access Control πŸŽ€

So when this bad boy gets compiled on Unix platforms with TCP wrapper support, you can turn on host-based access control with the --access-control command line option. Turn it on and the access control rules defined in your system's host access control tables for storescp are actually enforced β€” no vibes-based security here. ✨

The default locations of those host access control tables are:

  • /etc/hosts.allow
  • /etc/hosts.deny

Want the full lore? It's all described in hosts_access(5). Go read it, bestie, it's giving required reading. πŸ“š


🌸 Running storescp from inetd 🌸

On Posix platforms you can also launch storescp through the inetd(8) super server β€” yes, the classic. For that you gotta configure storescp in the /etc/inetd.conf configuration file. A typical configuration line could look, like, exactly like this:

acr-nema stream tcp nowait root /usr/sbin/storescp -id +ac -od /tmp/storescp

That's the whole vibe: the service name, the socket type, nowait, the user it runs as, the binary path, and then your flags doing their thing. Copy it, tweak it, live your truth. πŸ’–

...where -id (--inetd) turns on the inetd mode, and in that mode it's actually inetd that accepts the DICOM association and hands it over to storescp β€” she's just the one doing the actual work, iconic delegation honestly πŸ’…. Then +ac (--access-control) switches on the TCP wrapper based access control we were just talking about, and -od (--output-directory) tells her which directory to dump the incoming DICOM objects into.

Quick little heads-up bestie: the service name ("acr-nema" in this example) is what decides the port number that DICOM associations get accepted on, and it has to be defined in /etc/services or it's not happening. Also, when she's running from inetd, the stdout and stderr streams get discarded β€” like, gone, bye 😭. But you can still set up logging through the --log-config option (peep it below).

fr fr be careful here: when run through inetd, storescp is executed with root privileges, which may be a security risk. Not being dramatic, that's just what the page says πŸ’€

🧚 Association Negotiation Profiles and Configuration Files

storescp supports a flexible mechanism for specifying the DICOM network association negotiation behavior, based on so-called "association negotiationprofiles" which may be read from a configuration file. The format and semantics of this configuration file are documented in asconfig.txt.


✨ LOGGING ✨

Okay so the level of logging output β€” for the various command line tools and the underlying libraries β€” can be specified by you, the user 🫢. Here's the tea:

  • By default, only errors and warnings are written to the standard error stream.
  • Using option --verbose, informational messages like processing details get reported too.
  • Option --debug gives you more details on the internal activity, e.g. for debugging purposes.
  • Other logging levels can be selected using option --log-level.
  • In --quiet mode, only fatal errors are reported. And in those very severe error events, the application will usually terminate. 😭

For more details on the different logging levels, see documentation of module "oflog".

In case the logging output should be written to file (optionally with logfile rotation), to syslog (Unix) or the event log (Windows), option --log-config can be used. This configuration file also allows for directing only certain messages to a particular output stream and for filtering certain messages based on the module or application where they are generated. An example configuration file is provided in <etcdir>/logger.cfg 🌸


πŸ’» COMMAND LINE πŸ’»

All command line tools use the following notation for parameters: square brackets enclose optional values (0-1), three trailing dots indicate that multiple values are allowed (1-n), and a combination of both means 0 to n values. Not me memorizing this β€” it's giving syntax legend πŸ‘‘

Command line options are distinguished from parameters by a leading + or - sign, respectively. Usually, order and position of command line options are arbitrary (i.e. they can appear anywhere). However, if options are mutually exclusive, the rightmost appearance is used. This behavior conforms to the standard evaluation rules of common Unix shells.

In addition, one or more command files can be specified using an @ sign as a prefix to the filename (e.g. @command.txt). Such a command argument is replaced by the content of the corresponding text file (multiple whitespaces are treated as a single separator unless they appear between two quotation marks) prior to any further evaluation. Please note that a command file cannot contain another command file πŸ™ˆ. This simple but effective approach allows one to summarize common combinations of options/parameters and avoids longish and confusing command lines (an example is provided in file <datadir>/dumppat.txt).


🌍 ENVIRONMENT 🌍

The storescp utility will attempt to load DICOM data dictionaries specified in the DCMDICTPATH environment variable. By default, i.e. if the DCMDICTPATH environment variable is not set, the file <datadir>/dicom.dic will be loaded unless the dictionary is built into the application (default for Windows).

The default behavior should be preferred and the DCMDICTPATH environment variable only used when alternative data dictionaries are required. The DCMDICTPATH environment variable has the same format as the Unix shell PATH variable in that a colon (":") separates entries. On Windows systems, a semicolon (";") is used as a separator. The data dictionary code will attempt to load each file specified in the DCMDICTPATH environment variable. It is an error if no data dictionary can be loaded.


πŸŽ€ FILES πŸŽ€

  • <docdir>/asconfig.txt β€” configuration file documentation
  • <etcdir>/storescp.cfg β€” example association negotiation profile

πŸ¦‹ SEE ALSO πŸ¦‹


Copyright (C) 1996-2026 by OFFIS e.V., Escherweg 2, 26121 Oldenburg, Germany.


And that's the whole page, bestie β€” you ate that πŸ“βœ¨ This was storescp(1) from Version 3.7.1, dated Sat Oct 17 2026 09:34:01. Go forth and receive some DICOM objects, iykyk πŸ’œπŸ«Ά

πŸ“¦ where this page comes from