<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=ISO-8859-1">
</head>
<body bgcolor="#FFFFFF" text="#000000">
Hi all,<br>
<br>
I have to build an diameter DCCA proxy and thinking of doing it in
Erlang since diameter stack is available in OTP. I have to build
this because we have one diameter client which has burned-in set of
AVP's (it doesn't send MSCC AVP which is mandatory for billing
system) so I have to change an CCR message a bit and send it to OCS
- of course some bits need to be changed in answer also.<br>
<br>
I looked through relay.erl and relay_cb.erl in diameter examples and
noticed that it calls the following function with atom 'relay':<br>
<br>
<meta charset="utf-8">
<pre style="margin: 0px; padding: 0px; border: 0px; font-size: 12px; font-family: Consolas, 'Liberation Mono', Courier, monospace; color: rgb(51, 51, 51); font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 16px; orphans: 2; text-align: start; text-indent: 0px; text-transform: none; widows: 2; word-spacing: 0px; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px;"><div class="line" id="LC49" style="margin: 0px; padding: 0px 0px 0px 10px; border: 0px;"><span class="nf" style="margin: 0px; padding: 0px; border: 0px; color: rgb(153, 0, 0); font-weight: bold;">handle_request</span><span class="p" style="margin: 0px; padding: 0px; border: 0px;">(_</span><span class="nv" style="margin: 0px; padding: 0px; border: 0px; color: rgb(0, 128, 128);">Pkt</span><span class="p" style="margin: 0px; padding: 0px; border: 0px;">,</span> <span class="p" style="margin: 0px; padding: 0px; border: 0px;">_</span><span class="nv" style="margin: 0
px; padding: 0px; border: 0px; color: rgb(0, 128, 128);">SvcName</span><span class="p" style="margin: 0px; padding: 0px; border: 0px;">,</span> <span class="p" style="margin: 0px; padding: 0px; border: 0px;">_</span><span class="nv" style="margin: 0px; padding: 0px; border: 0px; color: rgb(0, 128, 128);">Peer</span><span class="p" style="margin: 0px; padding: 0px; border: 0px;">)</span> <span class="o" style="margin: 0px; padding: 0px; border: 0px; font-weight: bold;">-></span></div><div class="line" id="LC50" style="margin: 0px; padding: 0px 0px 0px 10px; border: 0px;"> <span class="p" style="margin: 0px; padding: 0px; border: 0px;">{</span><span class="n" style="margin: 0px; padding: 0px; border: 0px; color: rgb(51, 51, 51);">relay</span><span class="p" style="margin: 0px; padding: 0px; border: 0px;">,</span> <span class="p" style="margin: 0px; padding: 0px; border: 0px;">[{</span><span class="n" style="margin: 0px; padding: 0px; border: 0px; color: rgb(51,
51, 51);">timeout</span><span class="p" style="margin: 0px; padding: 0px; border: 0px;">,</span> <span class="mi" style="margin: 0px; padding: 0px; border: 0px; color: rgb(0, 153, 153);">1000</span><span class="p" style="margin: 0px; padding: 0px; border: 0px;">},</span> <span class="p" style="margin: 0px; padding: 0px; border: 0px;">{</span><span class="n" style="margin: 0px; padding: 0px; border: 0px; color: rgb(51, 51, 51);">extra</span><span class="p" style="margin: 0px; padding: 0px; border: 0px;">,</span> <span class="p" style="margin: 0px; padding: 0px; border: 0px;">[</span><span class="n" style="margin: 0px; padding: 0px; border: 0px; color: rgb(51, 51, 51);">relayed</span><span class="p" style="margin: 0px; padding: 0px; border: 0px;">]}]}.</span>
<span class="p" style="margin: 0px; padding: 0px; border: 0px;"></span>
<span class="p" style="margin: 0px; padding: 0px; border: 0px;"></span><span class="p" style="margin: 0px; padding: 0px; border: 0px;">
</span></div></pre>
Is it possible to change the _Pkt that is being relayed since it is
not a part of return statement?<br>
<br>
Or should I do separate client and server? <br>
<br>
Please advise,<br>
Ivan<br>
</body>
</html>