Question

  Asked: May 5 2008   8:32 PM GMT
  Asked by: Piano


User Exit Program for TELNET


User Exit Program FTP, User Exit Program TELNET, TELNET, AS/400 FTP

Does anyone know if a User Exit Program exists out there for TELNET application ?

I developed one for FTP, but was unaware that TELNET did not fall under this application.

Also, aside from TELNET, and FTP, are there other ways that people can get into the AS400 that I need to develop exit programs for ?

Please advise

-Nick

Subscribe to Alerts! Get questions and answers delivered to your Inbox.


E-mail me updates on this question



   SUBSCRIBE

hidden modal window

Answer Wiki (Improve, edit or add to this answer)


 RATE THIS ANSWER
+1
Click to Vote:
  •   1
  •  0



There are many points of entry into the system that allow external access. Some can be found here by paging to the end of the list and reviewing the TCP/IP Management exit programs. Others can be found here, and many more exist than I have referenced above.

Bruce Vining
  • AddThis Social Bookmark Button

Browse more Questions and Answers on AS/400 and Networking.

Looking for relevant AS/400 Whitepapers? Visit the Search400.com Research Library.


Discuss This Answer


You must be logged-in to discuss a question. Log-in/Register

Piano  |   May 7 2008  10:27AM GMT

Hi Bruce

Thank you for your response.

For an update, I read thru the IBM documentation. I then registered PROGRAM DEVINIT2 which I found off the interne as a sample program. It is registered under QIBM_QTG_DEVINIT.

Unfortunately, this program is of type C, and I do not know how to debug (or even if I can debug) this program.

Bottom line is that it is not preventing me as a user to TELENT in, and, I want to use myself as a “TEST” user, to see just exactly how this program works.

Alternatively, I would welcome any CLLE or CLP program samples that do the same thing. I need to be able to block out user profiles, based on user id’s that I have stored into a file which I set up file maintenance for. I am pretty sure that I can set up the DEBUB on a CLLE, or CLP program that is out there !

I hope I am making sense, and I do apprecaite all your feedback. You have no idea how much time you save me “going down a dirt road” becuase I was reading the wrong documentation.

Thank you, and I will anxiously await anyones response.

Sincerely

Nick

 

Mcl  |   May 7 2008  4:02PM GMT

Nick..

Google is your friend. I found what looks like a good article by searching for “AS/400 exit programs”. Article was on (can I say this here?) the ITJungle website. There is a CL example and some explanation.. No guarantees, but it might help.

Cheers
Mike

 

Bvining  |   May 7 2008  4:15PM GMT

Hi, Nick

You can debug C programs in the same manner that you debug CL or RPG programs. Compile the program using the DBGVIEW parameter as you would with other languages. Debugging is a bit more fun though (for any language) as the exit program is running in a Telnet job, not yours…

To try and help, here’s a quick and dirty CL program that checks explicitly for a user profile of TEST and, if found, closes the Telnet session.

Pgm Parm(&Usr_Info &Dev_Info &Conn_Info +
&Env_Opts &Len_Env &Alw_Conn &Alw_Auto)

Dcl Var(&Usr_Info) Type(*Char) Len(44)
Dcl Var(&UsrPrf) Type(*Char) Stg(*Defined) +
Len(10) DefVar(&Usr_Info 5)

Dcl Var(&Dev_Info) Type(*Char) Len(28)
Dcl Var(&Conn_Info) Type(*Char) Len(76)
Dcl Var(&Env_Opts) Type(*Char) Len(1)
Dcl Var(&Len_Env) Type(*Int)
Dcl Var(&Alw_Conn) Type(*Char) Len(1)
Dcl Var(&Alw_Auto) Type(*Char) Len(1)

If Cond(&UsrPrf = 'TEST') Then(Do)
ChgVar Var(&Alw_Conn) Value('0')
ChgVar Var(&Alw_Auto) Value('0')
EndDo
Else Cmd(Do)
ChgVar Var(&Alw_Conn) Value('1')
ChgVar Var(&Alw_Auto) Value('0')
EndDo
EndPgm

It appears to work with rather limited testing :-)

You’ll want to obviously supplement the user profile checking and, if you’re really going to store the profile names in a database, might be interested in a product I’m nearing completion on — CL support for files such as database keyed (and obviously arrival sequence) read/write/update/delete, display files, printer files, etc). I haven’t done the command online help, but some very nice functionality :-)

Bruce Vining
http://www.brucevining.com/

 

Bvining  |   May 7 2008  4:16PM GMT

PS - I used the V5R4 CL *Defined storage capability to define &Usr_Info as a structure. If you’re on an earlier release you would simply substring out the &UsrPrf value from the &Usr_Info parameter.

Bruce