function uencrypt(str:string;len:integer):string;//解密函数
var sch:string;
j,i:integer;
newstr:string;
begin
sch:='x&bsf0104MtTxR780926';
newstr:='';
j:=1;
for i:=1 to len do
begin
newstr:=newstr+chr(ord(str)-ord(sch[j]));
j:=j+1;
if j>20 then j:=1;
end;
result:=newstr;
end;
function encrypt(str:string;len:integer):string;//加密函数
var sch:string;
j,i:integer;
begin
sch:='x&bsf0104MtTxR780926';
Randomize;
j:=1;
for i:=1 to 255 do
begin
if i<=len then
str:=chr(ord(str)+ord(sch[j]))
else
str:=str+chr(random(255)+ord(sch[j]));
j:=j+1;
if j>20 then j:=1;
end;
result:=str;
end;