69 #include "dcmtk/config/osconfig.h" 71 #include "dcmtk/ofstd/ofglobal.h" 72 #include "dcmtk/ofstd/oftypes.h" 73 #include "dcmtk/ofstd/ofcast.h" 74 #include "dcmtk/dcmnet/extneg.h" 75 #include "dcmtk/dcmnet/dicom.h" 76 #include "dcmtk/dcmnet/dcuserid.h" 123 typedef void DUL_NETWORKKEY;
124 typedef void DUL_ASSOCIATIONKEY;
125 typedef unsigned char DUL_PRESENTATIONCONTEXTID;
139 #define DUL_LEN_TITLE OFstatic_cast(size_t, 16) 140 #define DUL_LEN_NAME OFstatic_cast(size_t, 64) 141 #define DUL_LEN_UID OFstatic_cast(size_t, 64) 142 #define DUL_LEN_NODE OFstatic_cast(size_t, 127) 147 #define DUL_TYPEASSOCIATERQ OFstatic_cast(unsigned char, 0x01) 148 #define DUL_TYPEASSOCIATEAC OFstatic_cast(unsigned char, 0x02) 149 #define DUL_TYPEASSOCIATERJ OFstatic_cast(unsigned char, 0x03) 150 #define DUL_TYPEDATA OFstatic_cast(unsigned char, 0x04) 151 #define DUL_TYPERELEASERQ OFstatic_cast(unsigned char, 0x05) 152 #define DUL_TYPERELEASERP OFstatic_cast(unsigned char, 0x06) 153 #define DUL_TYPEABORT OFstatic_cast(unsigned char, 0x07) 155 #define DUL_MAXTYPE OFstatic_cast(unsigned char, 0x07) 167 virtual void callback(
unsigned long mode) = 0;
171 char applicationContextName[DUL_LEN_NAME + 1];
172 char callingAPTitle[DUL_LEN_TITLE + 1];
173 char calledAPTitle[DUL_LEN_TITLE + 1];
174 char respondingAPTitle[DUL_LEN_TITLE + 1];
175 unsigned long maxPDU;
176 unsigned short result;
177 unsigned short resultSource;
178 unsigned short diagnostic;
179 char callingPresentationAddress[64];
180 char calledPresentationAddress[64];
181 LST_HEAD *requestedPresentationContext;
182 LST_HEAD *acceptedPresentationContext;
183 unsigned short maximumOperationsInvoked;
184 unsigned short maximumOperationsPerformed;
185 char callingImplementationClassUID[DICOM_UI_LENGTH + 1];
186 char callingImplementationVersionName[16 + 1];
187 char calledImplementationClassUID[DICOM_UI_LENGTH + 1];
188 char calledImplementationVersionName[16 + 1];
189 unsigned long peerMaxPDU;
195 OFBool useSecureLayer;
206 #define DUL_PRESENTATION_ACCEPT 0 207 #define DUL_PRESENTATION_REJECT_USER 1 208 #define DUL_PRESENTATION_REJECT_NOREASON 2 209 #define DUL_PRESENTATION_REJECT_ABSTRACT_SYNTAX 3 210 #define DUL_PRESENTATION_REJECT_TRANSFER_SYNTAX 4 216 DUL_PRESENTATIONCONTEXTID presentationContextID;
217 char abstractSyntax[DUL_LEN_UID + 1];
219 char acceptedTransferSyntax[DUL_LEN_UID + 1];
220 unsigned char result;
221 DUL_SC_ROLE proposedSCRole;
222 DUL_SC_ROLE acceptedSCRole;
227 char transferSyntax[DUL_LEN_UID + 1];
231 unsigned char result;
232 unsigned char source;
233 unsigned char reason;
249 unsigned long fragmentLength;
250 unsigned char presentationContextID;
259 unsigned long scratchLength;
271 #define DUL_ORDERMASK 0x03 272 #define DUL_ORDERLITTLEENDIAN 0x01 273 #define DUL_ORDERBIGENDIAN 0x02 275 #define DUL_DOMAINMASK 0x04 276 #define DUL_FULLDOMAINNAME 0x04 278 #define DUL_AEREQUESTOR "AE REQUESTOR" 279 #define DUL_AEACCEPTOR "AE ACCEPTOR" 280 #define DUL_AEBOTH "AE BOTH" 286 #define DUL_REJ_RSLTPERMANENT 0x01 287 #define DUL_REJ_RSLTTRANSIENT 0x02 294 #define DUL_SCU_INITIATED_ABORT 0x00 295 #define DUL_SCP_INITIATED_ABORT 0x02 297 #define DUL_ABORTSERVICEUSER 0x00 298 #define DUL_ABORTSERVICEPROVIDER 0x02 300 #define DUL_ABORTNOREASON 0x00 301 #define DUL_ABORTUNRECOGNIZEDPDU 0x01 302 #define DUL_ABORTUNEXPECTEDPDU 0x02 303 #define DUL_ABORTUNRECOGNIZEDPDUPARAM 0x04 304 #define DUL_ABORTUNEXPECTEDPDUPARAM 0x05 305 #define DUL_ABORTINVALIDPDUPARAM 0x06 311 #define DUL_REJECT_PERMANENT 0x01 312 #define DUL_REJECT_TRANSIENT 0x02 314 #define DUL_ULSU_REJECT 0x01 315 #define DUL_ULSP_ACSE_REJECT 0x02 316 #define DUL_ULSP_PRESENTATION_REJECT 0x03 318 #define DUL_ULSU_REJ_NOREASON 0x01 319 #define DUL_ULSU_REJ_UNSUP_APP_CTX_NAME 0x02 320 #define DUL_ULSU_REJ_UNREC_CALLING_TITLE 0x03 321 #define DUL_ULSU_REJ_UNREC_CALLED_TITLE 0x07 323 #define DUL_ULSP_ACSE_REJ_NOREASON 0x01 324 #define DUL_ULSP_ACSE_UNSUP_PROTOCOL 0x02 326 #define DUL_ULSP_PRES_REJ_TEMP_CONGEST 0x01 327 #define DUL_ULSP_PRES_REJ_LIMIT 0x02 329 #define DUL_ABORTNOREASON 0x00 330 #define DUL_ABORTUNRECOGNIZEDPDU 0x01 331 #define DUL_ABORTUNEXPECTEDPDU 0x02 332 #define DUL_ABORTUNRECOGNIZEDPDUPARAM 0x04 333 #define DUL_ABORTUNEXPECTEDPDUPARAM 0x05 334 #define DUL_ABORTINVALIDPDUPARAM 0x06 347 } DUL_ASSOCIATION_PARAMETER;
349 #define DUL_TIMEOUT 180 356 #define DUL_DULCOMPAT 2768240730UL 357 #define DUL_DIMSECOMPAT 655360UL 358 #define DUL_MAXPDUCOMPAT 4278190335UL 366 DUL_AcknowledgeAssociationRQ(
367 DUL_ASSOCIATIONKEY ** association,
369 int activatePDUStorage);
372 DUL_InitializeNetwork(
378 DUL_NETWORKKEY ** network);
381 DUL_ReceiveAssociationRQ(
382 DUL_NETWORKKEY ** net,
383 DUL_BLOCKOPTIONS blk,
386 DUL_ASSOCIATIONKEY ** association,
387 int activatePDUStorage);
390 DUL_RejectAssociationRQ(
391 DUL_ASSOCIATIONKEY ** association,
393 int activatePDUStorage);
396 DUL_RequestAssociation(
397 DUL_NETWORKKEY ** network,
399 DUL_ASSOCIATIONKEY ** association,
400 int activatePDUStorage);
404 OFCondition DUL_AbortAssociation(DUL_ASSOCIATIONKEY ** association);
405 OFCondition DUL_DropAssociation(DUL_ASSOCIATIONKEY ** association);
406 OFCondition DUL_DropNetwork(DUL_NETWORKKEY ** network);
407 OFCondition DUL_ReleaseAssociation(DUL_ASSOCIATIONKEY ** association);
408 OFCondition DUL_AcknowledgeRelease(DUL_ASSOCIATIONKEY ** association);
413 DUL_ReadPDVs(DUL_ASSOCIATIONKEY ** association,
414 DUL_PDVLIST * pdvList, DUL_BLOCKOPTIONS block,
int timeout);
416 DUL_WritePDVs(DUL_ASSOCIATIONKEY ** association,
424 DUL_AssociationParameter(DUL_ASSOCIATIONKEY ** association,
425 DUL_ASSOCIATION_PARAMETER param, DUL_DATA_TYPE type,
426 void *address,
size_t length);
429 DUL_SC_ROLE proposedSCRole, DUL_SC_ROLE acceptedSCRole,
430 DUL_PRESENTATIONCONTEXTID ctxID,
unsigned char reason,
const char *abstractSyntax,
431 const char *transferSyntax, ...);
433 OFString& DUL_DumpConnectionParameters(
OFString& str, DUL_ASSOCIATIONKEY *association);
446 DUL_dataWaiting(DUL_ASSOCIATIONKEY * callerAssociation,
int timeout);
448 DUL_networkSocket(DUL_NETWORKKEY * callerNet);
450 DUL_associationWaiting(DUL_NETWORKKEY * callerNet,
int timeout);
455 void DUL_activateAssociatePDUStorage(DUL_ASSOCIATIONKEY *dulassoc);
456 void DUL_returnAssociatePDUStorage(DUL_ASSOCIATIONKEY *dulassoc,
void *& pdu,
unsigned long& pdusize);
465 void DUL_activateCompatibilityMode(DUL_ASSOCIATIONKEY *dulassoc,
unsigned long mode);
466 void DUL_activateCallback(DUL_ASSOCIATIONKEY *dulassoc,
DUL_ModeCallback *cb);
471 unsigned long DUL_getPeerCertificateLength(DUL_ASSOCIATIONKEY *dulassoc);
472 unsigned long DUL_getPeerCertificate(DUL_ASSOCIATIONKEY *dulassoc,
void *buf,
unsigned long bufLen);
483 OFBool DUL_processIsForkedChild();
489 void DUL_markProcessAsForkedChild();
503 void DUL_requestForkOnTransportConnectionReceipt(
int argc,
char *argv[]);
509 void DUL_DumpConnectionParameters(DUL_ASSOCIATIONKEY *association, STD_NAMESPACE ostream& outstream);
this class represents a TCP/IP based transport connection which can be a transparent TCP/IP socket co...
virtual void callback(unsigned long mode)=0
callback method
factory class which creates transport layer connections.
double linked list template class.
Class for User Identity Negotiation request user item.
general purpose list class for use with dcmnet module.
a simple string class that implements a subset of std::string.
virtual ~DUL_ModeCallback()
destructor
Template class which allows to declare global objects that are protected by a Mutex if used in multi-...
General purpose class for condition codes.